Simply copy and paste the following command line in your terminal to create your first Strapi project.
npx create-strapi-app my-project
If you are new to building with Strapi, you may wonder how to handle migration across all environments for development, production, and testing. This article will help you decide which platform will be best for deploying your production app.
Strapi is an open-source headless content management system (CMS) built to provide ease while developing APIs with different features and working with all frontend GraphQL enabled frameworks. With Strapi, you can create content types, handle users, and manage images and audio using the media library.
You are required to host and communicate with your API on a live server. This article will focus on the different Strapi environments, what to consider before picking a deployment option, and their pros and cons.
Environment variables are provided to be used in Config files. Instead of writing the credentials across all config files, they are defined in a
.env file to configure development, production, and test environments.
Your project is in the Development environment when it is still being worked on locally. This is indicated in the structure and config; it is in the production environment once deployed.
The state of your environment affects the availability of certain features like the content-type builder. Watch this video to see how to migrate your content across environments.
Take complete control of your deployment and deploy on more robust platforms. Here is a list of the most popular recommendations and the advantages and limitations of some of these deployment options. That way, it’s easier to decide what works best for you.
Amazon AWS EC2 is a service offered as part of Amazon Web Services; it allows you to deploy your Strapi apps without worrying about how to scale or pay more than you utilize. Find their pricing on their website.
The Elastic Computer Service allows you to decide the geographical location for your instance; this improves reliability and eliminates network delay. It also runs on multiple operating from Linux, Fedora, and Redhat to Windows.
You can use the guide for help when setting up.
Azure is powered by Microsoft and offers Compute Service that runs on Windows and Linux, on which you can deploy complex applications. You can start without cost and pay on the go while scaling your application. The deployment guide is available in the documentation.
Digital Ocean offers Linux-based virtualized hardware, which can either be independent or part of a more extensive infrastructure, and access to firewalls, with unlimited scalability. Their pricing is flexible, and there is an extensive guide on how to get started.
Heroku is a cloud platform focused on applications and developer experience. They provide a secure, scalable database-as-a-service with constant threat monitoring and automatic operating system vulnerability patching.
You can extend applications for use with Heroku with over 200 Add-ons available in Heroku Elements Marketplace. There are different plans based on dyne hours per month; you can find the pricing on their website. If this is the option for you, you can get started using the deployment documentation.
The Platform.sh cloud allows developers to deploy their applications fast and worry less about scalability and database management. The main requirement is that you use Git to manage your application code.
Managing your stack on Platform.sh gives you features like Unified Environment, Multi-Services & Multi-App, Full Cluster Cloning Technology, Fail-Proof Deployments, and more. The deployment process is completed within minutes, and there is no downtime, and you can find the pricing on their website.
Render is a cloud-based solution for building and running apps, websites, and CDNs with free TLS certificates. They have flexible pricing and offer database management with PostgreSQL. If you are considering this option, you can follow the deployment guide here.
Strapi Cloud provides a holistic package that combines a server with a database, asset storage, a CDN (Content Delivery Network), and an email service. On top of these foundational elements, Strapi is highly customizable and will significantly enhance the experience for developers and content managers.
Disadvantages: -Tailored for SMBs: does not offer free or hobby plans.
When deciding on the best deployment option, there are many things to consider: project requirements, budget, team size, and deadlines. Hopefully, you have some great options to consider with that in mind.
The Strapi experience has always been about flexibility, customization, and open-source innovation. But we understand that managing infrastructure and scaling your application can sometimes be a daunting task, diverting your focus from what you do best: developing web experiences.
That's why we're excited to introduce Strapi Cloud, so you can leverage the same robust Strapi capabilities you love, but without the hassle of managing servers, worrying about uptime, or scaling infrastructure as your project grows. It will allow you to future-proof your apps with a CMS that meets the content management needs of all your stakeholders, no matter your use case, services or devices.
Strapi remains committed to open-source values, and self-hosting will always be a viable option. We believe in offering choices that align with your project's unique needs. Strapi Cloud is an additional resource for those who want to focus solely on development, leaving the infrastructure to us.
Aw are here to support you every step of the way, no matter which hosting option you choose. You can reach out to us and the community on our Discord if you have any questions!
Web and Blockchain Software Engineer who is passionate about using technology towards achieving SDGs, creating innovative solutions, open-source, and building communities. He is building EduKarma for innovative learning in Africa.