I feel like I've wasted so much time with Next JS

Reading cookies and API calls are basic features Next JS can handle easily. You really shouldn’t be making your own auth anyway; there are plenty of free open-source and paid solutions available.
Since you have iOS and Android apps, you already have a full backend somewhere. You only need a front-end framework for the web users of your app. Just use plain React with some plugins instead of a full-stack framework like Next JS.

TL:DR, it’s probably a skill issue.

I don’t really get your problem, but honestly this sounds like a you problem even though that sounds a bit harsh.
The differences between Next, Nuxt, Astro, and so on are pretty minor overall. Each of those frameworks can do what you want and has been used for that thousands of times. Yes, they all have quirks and features, but those shouldn’t hold you back as much as Next JS seems to. Your comment about hitting memory limits on Heroku because of Google Maps is confusing, and the idea of switching to PHP without knowing it is puzzling. No offense, we’ve all been there.
You already have an auth API for your RN app, so I’d recommend adding use client on every page and ignoring server-side rendering first. It may also help to avoid react-query for now, as it’s great for optimized calls but adds complexity, especially regarding data fetching and caching.
Once that’s running as a single-page app, you can look closer at rendering modes and improve things.

I really like SvelteKit. It has the benefit of being modeled after Next but aims to avoid the same issues.

I use Astro for just about every project now.

Harper said:
I use Astro for just about every project now.

Astro if most of your content is static with some interactivity.
Remix for CRUD apps.
“Vanilla” React for highly interactive single-page apps.
Note: This suggestion applies for around 2024.

Harper said:
I use Astro for just about every project now.

I started a Next JS project three years ago when both Next and Astro were in very different places… I wish I had a time machine for many reasons.

@Luca
A Gatsby believer has entered the chat

Tristan said:
@Luca
A Gatsby believer has entered the chat

Lol, this is not what I would have picked even in 2021.

Luca said:

Tristan said:
@Luca
A Gatsby believer has entered the chat

Lol, this is not what I would have picked even in 2021.

Oh, you probably would have. Back then, Next wasn’t as popular, but Gatsby was gaining traction.

The marketing was great: gather all your data sources, whether a database, an API, local Markdown files, XML feed, etc. Bring them to the frontend with GraphQL, pre-generate all the pages, and you have fast static site generation, with some dynamic parts too.

Not sure where it failed, but I assume it was due to reliance on GraphQL, which was likely overhyped and overengineered for many cases.

@Tristan
Gatsby was an option we explored and ultimately went with Next. Based on our experience, going back with a time machine wouldn’t have changed our choice.

@Luca
Is any of those reasons really saving lives?

Paxton said:
@Luca
Is any of those reasons really saving lives?

Sure, but if I’m already working with it, moving away from Next JS would be a bonus.

Next JS has been one of the best frameworks I’ve ever used. It’s very intuitive and easy to implement, and I regret not learning it sooner. What specific issues did you have?

It should have been even easier since you already have a working API.

@Teal
Three apps in three months?

Maybe he’s trying to build something larger than a simple ToDo app?