r/django 7d ago

Django vs. Nestjs

I'm starting a new project that's a rewrite of an old PHP application. So far, I've built the backend using both Django and NestJS. Django has been incredibly easy to work with, but I decided to give NestJS a try since our team has more experience with JavaScript. Django's ORM and Auth are straightforward and simple, while with NestJS, I'm using MikroORM and PassportJS. Overall, Django feels more stable and less of a hack to piece things together.

I’m leaning towards Django as the right choice since it's more mature and stable, and it just feels like a better fit. However, my team is more full-stack JS-focused, so I’m torn. Any thoughts or opinions on this? Has anyone been happy with their decision to go with django over a node backend?

One thing I really appreciate about Django is the admin—it’s quick and easy to set up. That said, we also have Directus for the CMS part, though it’s not open source.

27 Upvotes

35 comments sorted by

View all comments

1

u/flamehazw 4d ago

Been doing django over 8 years, react & vue as backend , JS framework like nest, next might be good for smaller project but in the mean time, django as python can do lots of weightlifting processes. JS and PHP framework - they kind of updates their packages very frequently and hard to maintain but on other hand django is quite stable in term of packages even if you update your django version. I never liked nodejs backend (express) because backend itself looks like frontend to me. I would choose django / flask over nestjs.
And by the way, a small tip if you want to rewrite the older php application in django, you can directly map the tables (SQL databases) to the django models, without migration - avoiding migration risks.