Local Development
Complete guide to developing MortarCMS websites locally, from setup to deployment. Learn how to use local development apps, manage environments, sync databases, and push changes to project environments.
Quick Start
- Download and install the MortarCMS Local Development App
- Connect to your organization and select a website
- Create or select a project environment
- Sync the database and pull the latest code
- Start local development server
- Make changes and test locally
- Push changes to your project environment
macOS App
The MortarCMS Local Development App for macOS provides a native interface for managing your local development environment.
Features:
- One-click project setup and environment switching
- Integrated database sync and management
- Real-time file watching and hot reloading
- Built-in terminal and log viewer
- Git integration with branch management
- Environment variable management
- Local SSL certificate generation
Download & Installation:
- Download the latest version from the MortarCMS platform
- Open the .dmg file and drag MortarCMS to Applications
- Launch the app and sign in with your MortarCMS account
- Grant necessary permissions when prompted
Command Line Interface
For developers who prefer command-line tools, MortarCMS provides a comprehensive CLI.
Troubleshooting Common Issues
Database sync fails
Check your internet connection and ensure you have proper permissions. Try syncing schema-only first.
Local server won't start
Ensure no other services are using the same ports. Check that all dependencies are installed.
Changes not reflecting
Clear browser cache, restart development server, or check if files are being watched correctly.
Project environment deployment fails
Check build logs for errors, ensure all environment variables are set, and verify Git branch is pushed.
Need Help?
If you're having trouble with local development, here are some resources:
- Check the documentation for detailed guides
- Contact support through the platform for technical assistance
- Join the developer community for tips and best practices
- Review the changelog for recent updates and changes