Skip to content
Pablo Rodriguez

Selecting Instance Type

An EC2 instance type defines the configuration of CPU, memory, storage, and network performance:

Instance typevCPUMemoryStorageNetwork performance
m5d.large24 GiB1 x 50 NVMe SSDUp to 10 Gbps
m5d.xlarge48 GiB1 x 100 NVMe SSDUp to 10 Gbps
m5d.8xlarge32128 GiB2 x 600 NVMe SSD10 Gbps

Note All current generation instance types support enhanced networking, except for T2 instances.

Instance type names follow a standard convention with multiple parts:

Example: c7gn.xlarge

  • Family: c (compute optimized)
  • Generation: 7 (seventh generation)
  • Processor family: g (AWS Graviton processor)
  • Additional capabilities: n (Network and EBS optimized)
  • Size: xlarge (extra-large instance)

Suitability of Instance Types for Workloads

Section titled “Suitability of Instance Types for Workloads”

General Purpose

Use cases: Web or application servers, enterprise applications, gaming servers, development or test environments

Instance types: M7, Mac, M6, M5, M4, T4, T3, T2

Provide a balance of compute, memory, and networking resources

Compute Optimized

Use cases: Batch processing, distributed analytics, high performance computing (HPC)

Instance types: C7, C6, C5, C4

Work well for compute-bound applications that benefit from high-performance processors

Storage Optimized

Use cases: High-performance databases, real-time analytics, transactional workloads

Instance types: I4, Im4, Is4, I3, D2, D3, H1

Designed for workloads requiring high, sequential read/write access to large datasets on local storage

Memory Optimized

Use cases: In-memory caches, high-performance databases, big data analytics

Instance types: R7, R6, R5, R4, X2, X1, Z1

Designed to deliver fast performance for workloads that process large datasets in memory

Accelerated Computing

Use cases: Machine learning, artificial intelligence (AI), HPC

Instance types: P5, P4, P3, P2, DL1, Trn1, Inf2, Inf1, G5, G4, G3, F1, VT1

Use hardware accelerators to perform functions more efficiently than software running on CPUs

HPC Optimized

Use cases: Deep learning workloads, compute-intensive HPC workloads

Instance types: Hpc7, Hpc6

Purpose built to offer the best price performance for running HPC workloads at scale on AWS

With over 270 available instance types, selection considerations include:

  • Analyze workload requirements for optimal performance
  • Choose instance type that provides needed performance while minimizing cost
  • Better to slightly under-spec initially and resize/scale as needed

Instance Types page in EC2 console:

  • Filter by characteristics you choose
  • Search and compare choices
  • Displays all available instance types in a Region

Recommendation Choose latest generation instance types for better price-to-performance ratio

AWS Compute Optimizer:

  • Recommends optimal instance type, instance size, and Auto Scaling group configuration
  • Analyzes workload patterns using Amazon Machine Learning
  • Classifies instance findings as:
    • Under-provisioned
    • Over-provisioned
    • Optimized
    • None (insufficient data or unsupported instance type)

Currently generates recommendations for M, C, R, T, and X instance families.

An EC2 instance type defines a configuration of CPU, memory, storage, and network performance characteristics. As a recommendation, choose new generation instance types in a family because they generally have better price-to-performance ratios. Use the Instance Types page in the Amazon EC2 console and AWS Compute Optimizer to find the right instance type for your workload.