Skip to main content
This page is part of an AI coding agent skill and is written for agents, not humans. For the human-readable Base44 docs, see the developer documentation.

base44 eject

Download the code for an existing Base44 project to your local machine.

Syntax

Options

What It Does

The eject command allows you to download the source code of a Base44 project that was created or managed through the platform:
  1. Lists all ejectable projects (projects with managed source code)
  2. Lets you select a project interactively (or specify via --app-id)
  3. Downloads the project code to a local directory
  4. Creates a new project as a copy (named “{Original Name} Copy”)
  5. Links the downloaded code to the new project
  6. Creates .env.local with the new project ID
  7. Optionally installs dependencies, builds, and deploys the project

Examples

Workflow

When you run eject:
  1. Project Selection: Choose from available ejectable projects
  2. Path Selection: Specify where to create the project (defaults to ./{project-name} or ./ if current directory is empty)
  3. Download: The project code is downloaded to the specified path
  4. New Project Creation: A copy of the project is created in Base44 (e.g., “My App Copy”)
  5. Linking: The local code is linked to the new project
  6. Optional Deployment: If the project has build commands configured, you’ll be asked if you want to deploy
    • Runs the install command (e.g., npm install)
    • Runs the build command (e.g., npm run build)
    • Deploys all resources with base44 deploy

Requirements

  • Must be authenticated (run npx base44 login first)
  • The project must be ejectable (have managed source code)
  • In non-interactive mode, both --app-id and --path are required

Use Cases

  • Download a project created through the Base44 dashboard
  • Clone a managed project for local development
  • Create a copy of an existing project to customize

Notes

  • The command creates a new project as a copy, preserving the original
  • The new project will be named “{Original Name} Copy”
  • The downloaded code is automatically linked to the new project
  • If the current directory is empty, the default path is ./
  • If the current directory has files, the default path is ./{kebab-case-project-name}
  • Only projects with isManagedSourceCode !== false can be ejected
  • If no ejectable projects exist, the command exits with “No projects available to eject.”