Replit: Complete Tutorial
Build and deploy apps from your browser with Replit and Replit Agent: workspace, prompting, databases and secrets, deployments, GitHub, templates and a project.
Replit: Complete Tutorial
Build and deploy apps from your browser with Replit and Replit Agent: workspace, prompting, databases and secrets, deployments, GitHub, templates and a project.
In one line
Replit is an online coding environment with an AI agent: describe an app, watch it get built, run it, and deploy it to a live URL, all in the browser without installing anything.
The 14 classes
Replit basics and the workspace
Get set up and understand the layout.
- Everything runs in the browser.
- Agent chat builds; Preview shows.
- Keep keys in Secrets.
Build your first app with Agent
From prompt to running app.
- Start with a mini-PRD.
- One change per prompt.
- Roll back with history.
Data, secrets and integrations
Add a database, API keys and services.
- Database for saved data.
- Secrets for keys.
- Use test mode for payments.
Deploy, domains and GitHub
Publish and keep the code safe.
- Deploy gives a public URL.
- Custom domain via DNS records.
- Push to GitHub for safety.
Prompt templates
Reusable prompts for common builds.
- Name pages, data and style.
- Ask for sample data.
- Ask for tests on key flows.
Prompting the Agent like a product manager
Write specs, checkpoints and reviews that get reliable results.
- Slice the work and review each slice.
- Write rules and edge cases in the prompt.
- Use checkpoints and Git for safety.
Three practical builds: internal tool, landing page with leads, and an API or bot
Build examples PMs actually need.
- Pick builds that match the goal.
- Add auth, validation and notifications deliberately.
- Define 'good enough' before building.
Data, authentication and integrations in detail
Design the data and logins properly.
- Model data first; protect it with auth and roles.
- Separate test and production.
- Confirm payments server-side.
Quality, security and performance checklist
Make your app safe enough to share.
- Security basics are mandatory before sharing.
- Test with two users and on a phone.
- Log errors and watch costs.
Git, collaboration, environments and handing over to engineers
Work with developers and move beyond a prototype.
- Use Git from day one.
- Prepare a handoff package.
- Know when to graduate to engineering.
When to use Replit vs Lovable vs other tools, and PM use cases
Choose the right builder.
- Match the tool to the job.
- Prototypes validate; engineers productionise.
- Use building to learn constraints.
Troubleshooting and FAQ: Replit
Fix common problems quickly.
- Reproduce first; give exact errors.
- Separate environment variables for deploys.
- Checkpoint working states.
Practice challenges with solutions: Replit
Test yourself on realistic tasks.
- Practise data, auth, scheduling and handoff.
- Keep secrets safe.
- Document for engineers.
Project, safety and cost
Ship and maintain a real app.
- Review what the agent wrote.
- Control usage and deployments.
- Privacy page for user data.
Further reading and tools
Interview questions
What is Replit Agent?
An AI that builds, runs and fixes apps in Replit from plain-English descriptions.
Where do API keys go?
In Secrets (environment variables), never in code or chat.
How do you deploy?
Use Deploy, pick a deployment type, add secrets, and optionally a custom domain.
Replit vs Lovable?
Replit gives a full coding environment with many languages and backends; Lovable focuses on front-end web apps with Supabase and GitHub sync.
What is Replit Agent best used for?
Turning a clear description into a working app quickly: prototypes, internal tools and small services, with a human reviewing and testing.
How do you write a good prompt for an AI app builder?
Describe users, pages, data, rules and edge cases, work in small slices, give examples, say what must not change, and ask for a plan before building.
How do you keep secrets safe?
Store them in Secrets or environment variables, never in code, prompts or repositories, and rotate any key that was exposed.
What are the deployment options and when to use them?
Static for simple sites, Autoscale for apps with variable traffic, Reserved VM for always-on services, and Scheduled for timed jobs (confirm current options).