Replit → Vercel Migration
Migrate a Replit project to Vercel: clean Replit files, update scripts, add secure SendGrid API route, audit DB, add docs, and prepare one-click production depl
Prompt
You are an AI agent. Migrate this project from Replit to Vercel. Requirements: - Remove all Replit-specific files/config (.replit, replit.nix, etc). - Update package.json scripts for Vercel (`dev`, `build`, etc). - Ensure the app builds and runs cleanly on Vercel (Node 20). - Default: rely on Vercel’s auto-detection for frameworks and serverless functions. - If auto-detection is not sufficient, create a `vercel.json` with the correct functions and routing. - Check and restructure all API routes so they conform to Vercel standards: - For Next.js → move endpoints into `pages/api/*` or `app/api/*/route.ts`. - For non-Next.js → implement endpoints as serverless functions under `api/*.ts`. - Ensure routes only expose what is safe to the client. Environment variables in Vercel: - SENDGRID_API_KEY (server-only, never exposed client-side) Email: - Implement a server route for SendGrid (e.g., `api/email/send`) that never exposes SENDGRID_API_KEY to the client. Database check: - If the project uses a database: - Inspect whether it has any tables or data. - If the DB is empty → skip migration (and remove DB code if unnecessary). - If the DB has data/tables → STOP and refer back to the user with a summary of what you found, asking for next steps before proceeding. Docs & hygiene: - Add `.env.local.example` showing SENDGRID_API_KEY. - Add `.gitignore`. - Add a short README with: overview, env var table, local dev, deploy steps, and API route notes. Deliverables: - Make code changes in-place. - Summarize changes (files touched + purpose). - List manual follow-ups (confirm SENDGRID_API_KEY in Vercel). - Provide simple deploy steps: 1) `npm i && npx vercel link` 2) Set SENDGRID_API_KEY in Vercel 3) `npx vercel --prod` Final step: - Commit and push all changes so the user can immediately test the deployment on Vercel.
AI consultant and software creator helping businesses and creators harness artificial intelligence through practical solutions and innovative products. Creator of BestPromptIdeas.com.
Reviews
0 reviewsNo reviews yet. Be the first to leave feedback.
Related prompts
View category →Architecture Review & Fix Strategy
AI chooses between minimal patch, structural refactor, or both; delivers concise architecture review and solution strategy.
Collaborative Coding Agent
Act as a coding agent that seeks approval before changes and pauses for testing. Review the provided codebase and deliver a concise high‑level summary.
Whole-Repo Architecture Review (Read-Only)
Run a read-only, whole-repo architecture review with sourced citations, risks, simplifications, target design, and a phased migration plan.
Modernize Objective-C App to Swift & SwiftUI
Convert an 11-year-old Objective-C app into a fully modern SwiftUI app with zero data loss, responsive UI, and native SwiftUI components.
Public Web Portfolio Audit & Cleanup
Audit a portfolio site’s public-facing code and assets for quality, security, and accessibility. Fix issues with reversible commits and produce SUMMARY.md.
Code Performance Analyzer
Analyze any codebase for runtime speed, bottlenecks, and efficiency improvements.