Replit integration

GitHub Import Missing Files on Replit

You imported a GitHub repository into Replit, but the project is incomplete. Some files and directories are missing, the app will not start, and you see errors about modules, configurations, or assets that should exist but do not.

Replit's GitHub import process does not always capture every file from a repository. Files excluded by .gitignore, files over certain size limits, symlinks, and files in submodules are commonly missed during import. The import also does not run post-clone hooks or setup scripts.

This is particularly confusing because the repository looks complete on GitHub but the Replit project is missing critical pieces needed to run the application.

Error Messages You Might See

MODULE_NOT_FOUND: Cannot find module './config' FileNotFoundError: .env: No such file or directory Error: Cannot find package.json ERROR: Could not find a required file: index.html
MODULE_NOT_FOUND: Cannot find module './config'FileNotFoundError: .env: No such file or directoryError: Cannot find package.jsonERROR: Could not find a required file: index.html

Common Causes

  • .gitignore exclusions — files like .env, node_modules, build artifacts, and config files are excluded by .gitignore and not imported
  • Large files excluded — files over Replit's size limit are silently skipped during import
  • Git submodules not cloned — submodule directories appear empty because submodules require separate initialization
  • Symlinks not resolved — symbolic links in the repository are not followed during import
  • LFS files not downloaded — files tracked by Git LFS are not pulled during the import

How to Fix It

  1. Check .gitignore — review the .gitignore file to understand which files were excluded, then create them manually in Replit
  2. Create missing .env file — add environment variables to Replit Secrets and create a .env file if your app reads from one
  3. Run npm install or pip install — dependency directories like node_modules are in .gitignore and must be reinstalled
  4. Initialize submodules manually — use the Shell to run git submodule init && git submodule update
  5. Download LFS files — install git-lfs and run git lfs pull in the Replit shell
  6. Compare with GitHub — view the repository on GitHub and manually verify which files are missing in your Replit project

Real developers can help you.

PawelPloszaj PawelPloszaj I'm fronted developer with 10+ years of experience with big projects. I have small backend background too Richard McSorley Richard McSorley Full-Stack Software Engineer with 8+ years building high-performance applications for enterprise clients. Shipped production systems at Walmart (4,000+ stores), Cigna (20M+ users), and Arkansas Blue Cross. 5 patents in retail/supply chain tech. Currently focused on AI integrations, automation tools, and TypeScript-first architectures. prajwalfullstack prajwalfullstack Hi Im a full stack developer, a vibe coded MVP to Market ready product, I'm here to help zipking zipking I am a technologist and product builder dedicated to creating high-impact solutions at the intersection of AI and specialized markets. Currently, I am focused on PropScan (EstateGuard), an AI-driven SaaS platform tailored for the Japanese real estate industry, and exploring the potential of Archify. As an INFJ-T, I approach development with a "systems-thinking" mindset—balancing technical precision with a deep understanding of user needs. I particularly enjoy the challenge of architecting Vertical AI SaaS and optimizing Small Language Models (SLMs) to solve specific, real-world business problems. Whether I'm in a CTO-level leadership role or hands-on with the code, I thrive on building tools that turn complex data into actionable value. Jaime Orts-Caroff Jaime Orts-Caroff I'm a Senior Android developer, open to work in various fields Victor Denisov Victor Denisov Developer Dor Yaloz Dor Yaloz SW engineer with 6+ years of experience, I worked with React/Node/Python did projects with React+Capacitor.js for ios Supabase expert Basel Issmail Basel Issmail ’m a Senior Full-Stack Developer and Tech Lead with experience designing and building scalable web platforms. I work across the full development lifecycle, from translating business requirements into technical architecture to delivering reliable production systems. My work focuses on modern web technologies, including TypeScript, Angular, Node.js, and cloud-based architectures. I enjoy solving complex technical problems and helping teams turn product ideas and prototypes into working platforms that can grow and scale. In addition to development, I often collaborate closely with product managers, business analysts, designers, and QA teams to ensure that solutions align with both technical and business goals. I enjoy working with startups and product teams where I can contribute both as a hands-on engineer and as a technical partner in designing and delivering impactful software. Mehdi Ben Haddou Mehdi Ben Haddou - Founder of Chessigma (1M+ users) & many small projects - ex Founding Engineer @Uplane (YC F25) - ex Software Engineer @Amazon and @Booking.com Costea Adrian Costea Adrian Embedded Engineer specilizing in perception systems. Latest project was a adas camera calibration system.

You don't need to be technical. Just describe what's wrong and a verified developer will handle the rest.

Get Help

Frequently Asked Questions

Why are some files missing after importing from GitHub?

Files listed in .gitignore (like .env, node_modules, build folders) are not tracked by Git and therefore not imported. You need to create these files manually or run install commands in Replit.

My app needs a .env file but it was not imported. What do I do?

Create the required environment variables in Replit's Secrets panel. If your app reads from a .env file directly, create one manually with the required variables.

Can I pull updates from GitHub after the initial import?

Yes, use the Git panel in Replit or run git pull in the Shell to sync with the latest changes from GitHub.

Related Replit Issues

Can't fix it yourself?
Real developers can help.

You don't need to be technical. Just describe what's wrong and a verified developer will handle the rest.

Get Help