• Documentation
  • Pricing
© 2026 Serverless, Inc. All rights reserved.

Framework

  • Overview
  • Documentation
  • Plugins360
  • Pricing

Learn

  • Blog
  • GuidesUpdated
  • Examples240
  • Courses

Resources

  • Support
  • Security
  • Trust Center
  • Status

Community

  • Slack
  • GitHub47k
  • Forum
  • Meetups

Company

  • About
  • Careers
  • Contact
  • Partners

Legal

  • Terms of Service
  • Privacy Policy
  • Trademark
  • DMCA
Serverless Framework Logo

Serverless Framework

Intro
SetupUpgrading To V4ConceptsTutorialAWS CredentialsLicense KeysVerifying Downloads
DeployingPackagingBuildingTestingDev ModeServicesFunctions
OverviewHTTP (API Gateway v2)REST (API Gateway v1)ActiveMQApplication Load BalancerAlexa SkillAlexa Smart HomeCloudWatch EventCloudWatch LogCloudFrontCognito User PoolEventBridge EventIoTIoT Fleet ProvisioningKafkaKinesis & DynamoDBMSKRabbitMQS3ScheduleSNSSQSWebsocket
Layers
OverviewTroubleshooting
Managed InstancesWeb Apps (Lambda Web Functions)Sandboxes (Lambda MicroVMs)MCP ServersAlertsVersion PruningDomainsIAM Function PermissionsParameters
OverviewSelf-reference serverless.ymlServerless CoreEnvironment VariablesCLI OptionsExternal YAML/JSON FilesJavascript propertiesGitDoppler
OverviewS3 ObjectsSSM Parameter Store & Secrets ManagerCloudFormation Stack Outputs
OverviewVaultTerraform State Output
ResourcesComposing ServicesDeployment BucketStateAgent SkillsPython support
OverviewRuntimeGatewayMemoryBrowserCode InterpreterDev Mode
API Gateway Proxy
OverviewGeneral ConfigurationAuthenticationAPI KeysData SourcesResolversPipeline FunctionsSubstitutionsCachingDelta SyncCustom DomainWAFCLI Commands
Deploying SAM/CFN TemplatesWorkflow Tips
OverviewCreating PluginsCLI OutputCustom CommandsCustom VariablesExtending the Configuration schemaExtending and overriding configuration
OverviewDashboardAxiom
Overviewagent docsagent inspectagent setupagent skills installagent skills list / readdeploydeploy functiondeploy listdevdiffinfoinvokeinvoke localloginlogin awslogin aws ssologsmetricspackageplugin installplugin uninstallprintprunereconcileremoverollbackrollback functionusage
OverviewConcepts
OverviewMetricsTracesTroubleshoot
OverviewNode.jsPython
OutputsProviders
OverviewBranch DeploymentsPreview DeploymentsCustom ScriptsTestingPrivate PackagesNotificationsMono ReposDeploy in your own CI/CDBest PracticesTroubleshootingFAQ
OverviewSetupToolsAWS Integration
Serverless.yml Reference
Examples and TutorialsConfiguration Validation
  1. Learn More
  2. Examples And Tutorials

Examples and tutorials

Start a new service from a built-in template, copy an example service that already does what you need, or follow a tutorial step by step. Templates and examples both come from the serverless/examples repository on GitHub.

Create a service from a template

To create a service from a built-in template, run serverless with no arguments in a folder without a serverless.yml or serverless-compose.yml file (in any of their formats, such as .yaml or .ts):

serverless

In a folder that has one of those files, the command sets up that service or Compose project instead of creating a new one. Otherwise it prompts for a template and a project name, downloads the template from the v4 branch of serverless/examples into a new folder named after the project, and then helps you sign in and set up AWS credentials. It needs an interactive terminal. The templates it offers:

TemplateFolder in serverless/examples
AWS / Node.js / HTTP APIaws-node-http-api
AWS / Node.js / Express APIaws-node-express-api
AWS / Node.js / Express API with DynamoDBaws-node-express-dynamodb-api
AWS / Node.js / Scheduled Taskaws-node-scheduled-cron
AWS / Node.js / Simple Functionaws-node
AWS / Python / HTTP APIaws-python-http-api
AWS / Python / Flask APIaws-python-flask-api
AWS / Python / Flask API with DynamoDBaws-python-flask-dynamodb-api
AWS / Python / Scheduled Taskaws-python-scheduled-cron
AWS / Python / Simple Functionaws-python
AWS / Compose / Serverless + Cloudformation + SAMcompose-multiframework

For the full walkthrough of the command, see Setting up the Serverless Framework.

Use an example service

The Serverless Framework examples page lists the official and community examples, and the serverless/examples repository holds the official ones, one folder per example. Each folder has a README.md that explains what the example deploys and how to run it.

To deploy an official example, clone the repository and deploy from the example's folder:

git clone https://github.com/serverless/examples
cd examples/aws-node-http-api
serverless deploy

Install the example's dependencies first when its README.md says so (for example npm install for a folder with a package.json).

Tutorials

  • Tutorial: Build an HTTP API with Lambda and DynamoDB: create, deploy, test and remove a first service with two Node.js functions and a DynamoDB table.
  • Setting up the Serverless Framework: install the CLI, sign in, set up AWS credentials and deploy a template.
  • Serverless blog: articles on building with the Framework.

Contribute an example

To share an example, open a pull request on serverless/examples. The repository's README.md describes how to add example code and how to list a community example that lives in your own repository.

Edit this page
Prev Serverless.yml ReferenceNextConfiguration Validation

Contents

  • Examples and tutorials
  • Create a service from a template
  • Use an example service
  • Tutorials
  • Contribute an example

Related

GuidesPluginsExamplesSlack CommunitySupport