Nextjs13 server actions in Netlify deployment


I am currently working with Nextjs 13.4.4 to rebuild an application I made with pure React.js. While working on the application I decided to use Nextjs new feature, ‘server actions’, that lets me use server functions within client components by passing them as props.

I wanted to see if my deployment on Netlify would work, so I decided to publish my unfinished application. Deployment was successful, but when I tried entering the website, it gave me a 500 error. Due to the progress I made in that repo (REPO I), I decided to create another repo (REPO II) to see what would be causing this 500 error after a successful deployment.

When utilizing ‘server actions’, you need to enable it in next.config.js by adding:

experimental: {
    serverActions: true,

After removing this and redeploying my application, the website worked. I wanted to know if anyone has had this problem and knows how to fix it. I would probably be able to use api routes, but server actions make things easier.

Here are links to my repos and website:


REPO II (recommended if you want to try out replicating the error):

Netlify Website:

I would also try contacting Nextjs support, but I wanted to try to find an answer here.

Thank you

The error you’re seeing is here: Server.edge not defined Error on nextJS SSR functions cause site to return 500 Errors