Choosing between REST APIs and HTTP APIs - Amazon API Gateway

Choosing between REST APIs and HTTP APIs

REST APIs and HTTP APIs are both RESTful API products. REST APIs support more features than HTTP APIs, while HTTP APIs are designed with minimal features so that they can be offered at a lower price. Choose REST APIs if you need features such as API keys, per-client throttling, request validation, AWS WAF integration, or private API endpoints. Choose HTTP APIs if you don't need the features included with REST APIs.

The following sections summarize core features that are available in REST APIs and HTTP APIs.

Endpoint type

The endpoint type refers to the endpoint that API Gateway creates for your API. For more information, see Choose an endpoint type to set up for an API Gateway API.

Endpoint types REST API HTTP API

Edge-optimized

Regional

Private

Security

API Gateway provides a number of ways to protect your API from certain threats, like malicious actors or spikes in traffic. To learn more, see Protecting your REST API and Protecting your HTTP API.

Authorization

API Gateway supports multiple mechanisms for controlling and managing access to your API. For more information, see Controlling and managing access to a REST API in API Gateway and Controlling and managing access to an HTTP API in API Gateway.

1 You can use Amazon Cognito with a JWT authorizer.

2 You can use a Lambda authorizer to validate JWTs for REST APIs.

API management

Choose REST APIs if you need API management capabilities such as API keys and per-client rate limiting. For more information, see Distributing your REST API to clients, Setting up custom domain names for REST APIs, and Setting up custom domain names for HTTP APIs.

Development

As you're developing your API Gateway API, you decide on a number of characteristics of your API. These characteristics depend on the use case of your API. For more information see Developing a REST API in API Gateway and Developing an HTTP API in API Gateway.

Monitoring

API Gateway supports several options to log API requests and monitor your APIs. For more information, see Monitoring REST APIs and Monitoring your HTTP API.

Integrations

Integrations connect your API Gateway API to backend resources. For more information, see Setting up REST API integrations and Configuring integrations for HTTP APIs.