---
title: "Installation Methods"
description: "Review all installation methods for using Sentry in AWS Lambda functions"
url: https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/
---

# Installation Methods | Sentry for AWS Lambda

* #### [Lambda Layer](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/layer.md)

  Learn how to add the Sentry Node Lambda Layer to use Sentry in your Lambda functions

* #### [NPM Package](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/npm.md)

  Learn how to install the Sentry AWS NPM package to use Sentry in your Lambda functions

### [Should I use the Lambda Layer or the NPM package?](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install.md#should-i-use-the-lambda-layer-or-the-npm-package)

We generally recommend using the Lambda layer as it doesn't require you to deploy any Sentry dependency alongside your function. With the layer, you can achieve the same level of customization as with the NPM package. There are two reasons why you still might want to use the NPM package instead:

1. You want to minimize lambda function size and tree-shake parts of the SDK code that you don't need. A related reason might be because you're transpiling your code and want to transpile your dependencies as well.
2. You already use NPM packages and deploy `node_modules` with your function and you don't want to add a (or another) Lambda layer to your functions.

## Pages in this section

- [Lambda Layer](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/layer.md)
- [Lambda Layer - CJS](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/layer__v7.x.md)
- [Lambda Layer - CJS](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/layer__v8.x.md)
- [Lambda Layer - CJS](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/layer__v9.x.md)
- [NPM Package](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/npm.md)
- [NPM Package](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/npm__v9.x.md)
- [NPM package - CJS](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/cjs-npm__v9.x.md)
- [NPM Package - ESM](https://docs.sentry.io/platforms/javascript/guides/aws-lambda/install/esm-npm__v9.x.md)
