Netlify Functions

Serverless functions are superpowers for web developers! Securely handle server-like requirements at any scale with no provisioning, scaling, or ops overhead.

← back to home

Create Your First Serverless Function

Create a new file at /netlify/functions/hello-world.js and put the following inside:


exports.handler = () => {
  return {
    statusCode: 200,
    body: 'hello world!',
  };
};

Save it, then run netlify dev to test locally. Check your work by clicking the button below!