Payload v3, The Ultimate CMS

7 min. read |
Article
Hey, Can you make this heading a different shade of black and move this Nav Item to the bottom instead of top. Shouldn't take you more than 15 minutes tops - Marketing Guy

To solve this never-ending problem, CMS (Content Management Systems) were introduced.

So a developer can just say "DO IT YOURSELF, Ya Punk" next time he gets a request to change the button colour for the 10th time.

What the hell is a CMS?

The idea was to provide an easy, rich, and effective way for non-developers to modify the content on large content-heavy websites without ever touching code.

Basically, the developer can take care of the functionality and features and the "Marketing Experts" can manage and update the content however they want.

It all started with WordPress (the OG of CMS) which bridges the gap between a developer and a business person.

It has a wide plugin system for almost every feature you can imagine in a content-heavy website from mailing lists to e-commerce funnels, you name it.

PHP Lambo bros loved it as it got the job done.

Then, the wave of JAM(Javascript API Markup) Stack apps came around 2017 - 19ish and made it way easier for a programmer to please the shareholders.

A whole ecosystem of tools was built to develop websites that are FAST AF, SEO friendly, and easily maintainable both with code (for programmers) and UI interfaces (marketers).

This wave also brought a whole new generation of "headless" CMS into the mainstream developer community. You can find a list of them on the JAM Stack Website.

Now unlike WordPress or its other counterparts, the ideology behind headless CMS is that the developer should BYOUI (bring your own UI) and it takes care of the content.

This gave them the ability to develop their UI in whatever framework they wanted and just consume the content stored in their CMS via an API or an SDK.

Why Payload is different than the others?

Now over the years, I've tried many of these headless CMS' like Sanity.io, Strapi, Contentful and many more and all of them are great and flexible in their own ways. They all allow a lot of content blocks (Text, Date, Media etc.) and are easy to work with both from a developer and a business standpoint.

But at the end of the day, I'm a developer and I value DX (unlike those marketing guys). I want something as close to my source code as possible.

In a way, sanity.io solved this as you can define your content collections along with your business code in your project.

I like Sanity very much, a lot of my projects are built with it.

But Payload gives you even better (and granular) control as you OWN the underlying tech and infra to the code as well and it ships with your app.

This means that there's no magic going on behind the scenes.

Let's understand this with an example, suppose I want a blog website where my CMS handles the content. I'm using NextJS as my preferred choice of the framework but it doesn't matter much as almost every CMS exposes its API over HTTP.

If I'm using any other CMS, I have to create the schema there and consume it through my app and it will be hosted either on a managed server provided by the company (in case of sanity or contentful) or I have to self-host it separately on a VPS (in case of Strapi) and I would have no idea what the hell is GROQ?

But In payload, Your CMS ships with you, which means you have a single source of truth for your UI, business logic, and Content management all in one place.

Why Should I Care?

In short, it'll save you time, cost you less and it's not just for handling content anymore.

If it was any other CMS where you don't know what DB is getting used in the background, how are they handling queries, relations, user access and 10 other things, you would most likely only put non-sensitive content, use it in a static landing page, newsletter, course content and call it a day.

But with payload especially with v3 stable and the long list of features it provides, you can build the next Facebook if you want.

At this point, It's not just a CMS but a established Typescript-based Backend as a Service for NextJS around my favourite databases with auth built-in which can be deployed along with my app.

Some of its features include:

  1. Ability to choose your own DB: Postgres, Mongo and now Sqlite too with its new drizzle adapter.
  2. Role-based Access Control for easy user management.
  3. Magic link signups with forgot and reset password functionality
  4. A wide variety of Plugins for everything from SEO to cloud Buckets to Stripe and a lot more.
  5. Everything is Configurable in the Admin Dashboard because everything is just a react component styled with Sass or TaiwindCSS from fields to views.
  6. Internationalisation and Dark mode support out of the box.
  7. Supports the latest Next 15 along with React 19 Server components, so you can expect faster live previews thanks to the new React Compiler.
  8. The payload team also introduced Job queues and cron jobs from v3.

I'd highly recommend watching the official release video of v3.0 by the Payload team to understand its capability and limitations.

My Experience

I've been following the payload journey since about a year ago when I saw this video on the JavaScript Mastery Channel.

I'm an active member of its Discord server and am constantly engaged in conversations about ongoing issues.

But I've never used it much as before v3, it supported GraphQL by default and I hate am not a big fan of it.

Therefore If I really wanted to learn and play around with it, I'd have to set it up from scratch and not many resources were available for it.

Thankfully Josh dropped this video so it was not a complete nightmare relatively simple to set it up.

The problem was neither NextJS nor Payload was stable at that time so I had to "glue together" a half-baked solution with TRPC and ExpressJS for it to work properly.

Well, about 4 months later, all of the above changed and v3 is now out and ready.

I've migrated my project from v2 to v3 which resulted in much less code with new and stable features and is a joy to maintain and work with.

You can check out the project on GitHub. It includes both the version so you can compare the differences and improvements.

For my use case, I didn't get to utilise many new features like live previews, search, custom admin components and more. So if you want to see a complete app with all these included. You can clone this starter website template from the Payload repo.

Therefore I'd highly recommend trying out payload if you have a NextJS app, are short on time, don't want to build your own admin dashboard, or roll your own auth solution without compromising on security and performance.

You can watch Bytegrad's video on how to get started with Payload v3. to get started with Payload.

Well, this is it for this one.

Pheww, this took a while. I'll try to write more articles like this at least once a month.

let's see how disciplined I am this year so no promises🤞

Until Next Time,

Happy Debugging Coding👋 and Happy New Year

Back To Articles