DEV Community

Cover image for How I built a cost-effective serverless landing page for my businesses
Evandro Pires for AWS Heroes

Posted on

How I built a cost-effective serverless landing page for my businesses

As a multi-business entrepreneur with distinct brands and domains, I needed a smart, scalable way to publish lead-capturing landing pages—without breaking the bank. Here's how I used AWS serverless technologies to make that happen.

The Problem

Running multiple businesses means juggling different audiences, branding strategies, and domain names. One of the most effective tools in my marketing stack is the classic lead-gen landing page—offer value (like an eBook), get a contact in return.

My go-to tool for landing pages was great—until I needed to use it across multiple domains. The moment I tried to scale beyond a single domain, the monthly cost jumped from R$79 to R$1200 (BRL). That made no sense for my needs or budget.

So I asked myself:

What if I could build my own landing page infrastructure using AWS serverless services?

Spoiler: I did. And it works beautifully—for almost free.

The Solution

I built a fully serverless, deployable landing page system that:

  • Works across any domain I own
  • Runs on AWS's free tier (with marginal cost when scaling)
  • Stores leads in DynamoDB
  • Sends confirmation emails via SES
  • Hosts HTML/CSS/JS from S3 + CloudFront
  • Can be cloned and customized in minutes

To make it even better, I integrated Amazon Q Developer to generate the initial HTML skeleton. It helped me overcome my design limitations and ship fast.

✅ You can find and use the open-source repo here

Architecture Overview

Here’s how each AWS service plays its role:

Amazon S3

  • Hosts static assets: HTML, CSS, JS, PDF eBook
  • Configured for static website hosting
  • Public access for landing page, private access for eBook

Amazon CloudFront

  • Distributes content globally
  • Handles HTTPS and custom domains
  • Reduces latency and adds DDoS protection

API Gateway

  • Exposes a POST endpoint for form submissions
  • Validates inputs and forwards to Lambda

AWS Lambda

  • Validates and stores form data in DynamoDB
  • Sends emails via SES
  • Returns a URL to download the eBook

Amazon DynamoDB

  • Stores user registration data
  • Schema-less and scales automatically

Amazon SES

  • Sends email confirmations to users
  • Notifies me about new submissions

Serverless Framework

  • Used for Infrastructure as Code (IaC)
  • Deploys all resources with a single command
  • Manages environment variables, roles, and permissions

Deployment Simplicity

Once you clone the repo and configure environment variables, the setup is:

serverless deploy
Enter fullscreen mode Exit fullscreen mode

That’s it. Your landing page goes live, and you’re ready to collect leads securely and reliably.

Real-World Use Case: E-book Download Page

I used this solution to create a lead magnet for one of my businesses. Here’s what it does:

  1. Visitor sees the landing page
  2. Fills out a form to get an eBook
  3. Gets the PDF immediately + confirmation email
  4. I receive the lead data and can follow up later

Why This Works

✅ Cost-Effective

You pay only for what you use. No servers. No idle costs.

✅ Scalable

Traffic spike? No problem. AWS handles it for you.

✅ Reliable & Secure

With HTTPS, IAM, DDoS protection, and Amazon's SLAs.

✅ Easy to Maintain

Update HTML, deploy changes via GitHub—no backend maintenance.

Who Should Use This

This solution is ideal for:

  • Entrepreneurs managing multiple brands/domains
  • Startups with lean budgets
  • Developers looking for marketing autonomy
  • Anyone needing a secure lead-gen solution that scales

Visit the demo page here


Final Thoughts

Sometimes the best solution is building your own.

If you’re a developer-entrepreneur juggling costs and domains like me, this approach might be your next favorite tool. It's fast, cheap, scalable—and entirely yours.

Feel free to clone the repo, make it yours, and publish landing pages that convert without the SaaS pricing trap.


About Me

This is Evandro Pires. I'm a husband, father of two, but also an AWS Serverless Hero, Serverless Guru Ambassador, Entrepreneur, CTO, Podcaster, and Speaker.

Cut costs and boost innovation by building a serverless-first mindset with sls.guru

Join our team and help transform the digital landscape for companies worldwide!

Top comments (2)

Collapse
 
nevodavid profile image
Nevo David

Pretty cool seeing someone skip the SaaS trap and just build their own setup from scratch. Respect.

Collapse
 
nathan_tarbert profile image
Nathan Tarbert

This is perfect for someone like me who hates paying for extra stuff and wants full control.

Some comments may only be visible to logged-in visitors. Sign in to view all comments.