{"id":293530,"date":"2019-08-02T07:13:18","date_gmt":"2019-08-02T14:13:18","guid":{"rendered":"https:\/\/css-tricks.com\/?p=293530"},"modified":"2020-01-14T10:41:01","modified_gmt":"2020-01-14T17:41:01","slug":"using-netlify-forms-and-netlify-functions-to-build-an-email-sign-up-widget","status":"publish","type":"post","link":"https:\/\/css-tricks.com\/using-netlify-forms-and-netlify-functions-to-build-an-email-sign-up-widget\/","title":{"rendered":"Using Netlify Forms and Netlify Functions to Build an Email Sign-Up Widget"},"content":{"rendered":"

Building and maintaining your own website is a great idea. Not only do you own your platform<\/a>, but you get to experiment with web technologies along the way. Recently, I dug into a concept called serverless functions, starting with my own website<\/a>. I\u2019d like to share the results and what I learned along the way, so you can get your hands dirty, too!<\/p>\n

<\/p>\n

But first, a 1-minute intro to serverless functions<\/h3>\n

A serverless function (sometimes called a lambda function or cloud function) is a piece of code that you can write, host, and run independently of your website, app, or any other code. Despite the name, serverless functions do, indeed, run on a server<\/a>; but it\u2019s a server you don\u2019t have to build or maintain. Serverless functions are exciting because they take a lot of the legwork out of making powerful, scalable, apps.<\/p>\n

There\u2019s lots of great information on serverless functions out there, and a great place to start is CSS Trick\u2019s own guide: The Power of Serverless Front-End Developers<\/a>.<\/p>\n

The Challenge: Build a Mailing List Sign Up Form<\/h3>\n

I started my journey with a challenge: I wanted to have an email list sign-up form on my site. The rules are as follows:<\/p>\n