AWS Builder Center
Secure Serverless Password Generator — One Lambda, Zero Servers, Infinite Passwords

Secure Serverless Password Generator — One Lambda, Zero Servers, Infinite Passwords

A cryptographically secure password generator built on a single AWS Lambda function. No servers, no S3, no API Gateway — just one Function URL that serves the full app. Free forever on AWS Free Tier. 🔐⚡

I am a DevOps Engineer with 3+ YOE in IT Industry

Weekend Showcase Challenge: Secure Serverless Password Generator — One Lambda, Zero Servers, Infinite Passwords




🌟 Vision & What It Does

In today's digital world, weak passwords are one of the leading causes of security breaches. Most people reuse simple passwords because generating strong ones is inconvenient. I wanted to solve this with the simplest possible tool — a free, instant, serverless password generator that anyone can use from their browser with zero installation.
The Secure Serverless Password Generator lets you:
  • 🔐 Generate cryptographically secure passwords instantly
  • 🎛️ Customize length (8–64 characters) with a live slider
  • ✅ Toggle uppercase, lowercase, numbers, and symbols
  • 📊 See real-time password strength scoring (Weak / Medium / Strong)
  • 📋 Copy to clipboard in one click
  • 📱 Use it on any device — mobile, tablet, or desktop
The best part? It runs entirely on AWS Lambda — no servers, no databases, no S3 buckets. Just one function and a live HTTPS URL that anyone in the world can visit.


🏗️ How I Built It

The Idea

This project started from a simple frustration — every password generator I found was either cluttered with ads, required an account, or I wasn't sure if it was actually secure. I wanted something clean, trustworthy, and built on infrastructure I control.
During the AWS Summer Build Series, I learned about Lambda Function URLs — a feature that gives your Lambda function a direct public HTTPS endpoint without needing API Gateway or S3. That was the lightbulb moment. I could serve both the HTML frontend AND handle the password generation logic from a single Lambda function.

Key Decisions

1. Lambda Function URL over API Gateway + S3 Instead of the traditional setup (S3 for frontend + API Gateway + Lambda for backend), I used a Lambda Function URL to serve everything from one place. This simplified the architecture dramatically and eliminated S3 public access configuration headaches entirely.
2. Python 
 secrets 
 module over 
 random 
 Security was non-negotiable. Python's built-in 
 random 
 module is NOT cryptographically secure. I used the 
 secrets 
 module instead, which is designed specifically for generating cryptographically strong random values — exactly what passwords need.
3. Serving HTML directly from Lambda The Lambda function detects whether the request is a browser page load (GET without parameters) or a password generation request (GET with 
 ?generate=true 
). For page loads, it returns the full HTML/CSS/JS as a response. For generation requests, it returns JSON. This means zero external dependencies.

Challenges

  • CORS and browser security: Since the frontend and backend are the same Lambda URL, CORS wasn't an issue — the page calls itself!
  • Keeping it lightweight: I deliberately avoided external libraries or frameworks. Pure HTML, CSS, and vanilla JavaScript means the page loads in milliseconds.
  • Strength scoring: Building a meaningful strength algorithm that considers length, character variety, and entropy took a few iterations to feel accurate and useful.


☁️ AWS Services Used & Architecture Overview

Services

Service
Purpose
Cost
AWS Lambda
Serves HTML frontend + generates passwords
Free Tier (1M req/month)
Total AWS cost: $0 ✅

Architecture User's Browser │ ▼ AWS Lambda Function URL (Public HTTPS endpoint) GET / → Returns HTML GET /?gener → Returns JSON Python secrets module Strength scoring logic

This is intentionally the simplest possible serverless architecture. One function. One URL. Fully managed by AWS. No infrastructure to maintain, patch, or scale Lambda handles all of that automatically.

Why Lambda Function URLs?

Lambda Function URLs were introduced to make exactly this kind of lightweight app possible. Instead of provisioning API Gateway (which adds cost and complexity) or hosting static files on S3 (which requires public access configuration), a Function URL gives you:
  • ✅ Instant HTTPS endpoint
  • ✅ No additional services needed
  • ✅ Scales automatically from 0 to millions of requests
  • ✅ Included in the Lambda Free Tier



📚 What I Learned Across the Summer

This summer's build series pushed me to think differently about cloud architecture. Here are my biggest takeaways:
1. Simplicity is a feature. The best architecture is often the one with the fewest moving parts. Starting with "what's the minimum AWS service I need?" led me to a cleaner, cheaper, and more maintainable solution.
2. Lambda is more powerful than I thought. I used to think of Lambda as just a "backend function." This summer I learned it can serve web pages, handle routing, process AI responses, and act as a complete application — all in one place.
3. Security starts at the code level. Using 
 secrets 
 instead of 
 random 
 is a small change with a huge impact. The Summer Build Series made me think about security at every layer — from the AWS IAM permissions I grant, to the cryptographic libraries I choose in code.
4. AWS Free Tier is genuinely powerful for builders. Every project I shipped this summer ran at essentially zero cost. Lambda's 1M free requests per month, combined with Bedrock's Nova Lite model pricing, means you can build and share real production-quality apps without a credit card bill.
5. Ship early, iterate fast. The weekend format forced me to prioritize ruthlessly. I shipped imperfect things, got feedback, and improved them. That cadence is more valuable than waiting for perfection.



🔗 Links




🏷️ Tags

#application



🙌 Shoutout

A huge thank you to @benfowleraws as build during the creative app weekend inspired me to think about how everyday tools can be reimagined with serverless architecture. Keep shipping! 🚀


Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article