What is Subnetter?
Subnetter is a specialized tool that automates the allocation of IPv4 CIDR blocks across cloud infrastructure environments. It eliminates the complexity and error-prone process of manual IP address management by providing deterministic, hierarchical, and conflict-free subnet allocation.
Multi-Cloud Support
Designed to work across AWS, Azure, GCP, and other cloud providers with consistent subnet allocation patterns.
Deterministic Results
Generate the same IP allocations every time, allowing consistent environment rebuilds and disaster recovery.
Hierarchical Allocation
Allocates IP space logically through accounts → regions → availability zones → subnet types.
No IP Conflicts
Automatically prevents overlapping IP ranges across your entire infrastructure.
Why Subnetter?
Manual allocation is error-prone
Hand-crafting CIDR blocks for hundreds of subnets leads to mistakes and overlaps.
Complex multi-cloud environments
Each cloud provider requires its own network architecture but needs to integrate with others.
Growing organizations need planning
Without proper IP allocation strategy, organizations need painful re-IP projects as they scale.
Documentation becomes outdated
Network diagrams and spreadsheets quickly become outdated as infrastructure evolves.
How It Works
Subnetter takes a hierarchical approach to IP allocation, dividing your IP space systematically across multiple cloud providers:
flowchart TD
BaseCIDR["Base CIDR
10.0.0.0/8"] --> AWS["AWS
10.0.0.0/12"]
BaseCIDR --> Azure["Azure
10.16.0.0/12"]
BaseCIDR --> GCP["GCP
10.32.0.0/12"]
%% AWS branch
AWS --> AWSProd["Account: Production
10.0.0.0/16"]
AWS --> AWSDev["Account: Development
10.1.0.0/16"]
AWS --> AWSStage["Account: Staging
10.2.0.0/16"]
%% AWS Production Account
AWSProd --> AWSUsEast["Region: us-east-1
10.0.0.0/20"]
AWSProd --> AWSUsWest["Region: us-west-2
10.0.16.0/20"]
AWSUsEast --> AWSUsEast1a["AZ: us-east-1a
10.0.0.0/22"]
AWSUsEast --> AWSUsEast1b["AZ: us-east-1b
10.0.4.0/22"]
AWSUsWest --> AWSUsWest2a["AZ: us-west-2a
10.0.16.0/22"]
AWSUsWest --> AWSUsWest2b["AZ: us-west-2b
10.0.20.0/22"]
AWSUsEast1a --> AWSPublic1["Subnet: Public
10.0.0.0/24"]
AWSUsEast1a --> AWSPrivate1["Subnet: Private
10.0.1.0/24"]
%% Azure branch
Azure --> AzureProd["Account: Production
10.16.0.0/16"]
Azure --> AzureDev["Account: Development
10.17.0.0/16"]
Azure --> AzureStage["Account: Staging
10.18.0.0/16"]
%% Azure Production Account
AzureProd --> AzureEastUS["Region: eastus
10.16.0.0/20"]
AzureProd --> AzureWestUS["Region: westus
10.16.16.0/20"]
AzureEastUS --> AzureEastUS1["AZ: eastus-1
10.16.0.0/22"]
AzureEastUS --> AzureEastUS2["AZ: eastus-2
10.16.4.0/22"]
AzureWestUS --> AzureWestUS1["AZ: westus-1
10.16.16.0/22"]
AzureWestUS --> AzureWestUS2["AZ: westus-2
10.16.20.0/22"]
AzureEastUS1 --> AzurePublic1["Subnet: Public
10.16.0.0/24"]
AzureEastUS1 --> AzurePrivate1["Subnet: Private
10.16.1.0/24"]
%% GCP branch
GCP --> GCPProd["Account: Production
10.32.0.0/16"]
GCP --> GCPDev["Account: Development
10.33.0.0/16"]
GCP --> GCPStage["Account: Staging
10.34.0.0/16"]
%% GCP Production Account
GCPProd --> GCPUsEast["Region: us-east1
10.32.0.0/20"]
GCPProd --> GCPUsWest["Region: us-west1
10.32.16.0/20"]
GCPUsEast --> GCPUsEast1b["AZ: us-east1-b
10.32.0.0/22"]
GCPUsEast --> GCPUsEast1c["AZ: us-east1-c
10.32.4.0/22"]
GCPUsWest --> GCPUsWest1a["AZ: us-west1-a
10.32.16.0/22"]
GCPUsWest --> GCPUsWest1b["AZ: us-west1-b
10.32.20.0/22"]
GCPUsEast1b --> GCPPublic1["Subnet: Public
10.32.0.0/24"]
GCPUsEast1b --> GCPPrivate1["Subnet: Private
10.32.1.0/24"]
%% Styling
classDef baseCidr fill:#f5f5f5,stroke:#333,stroke-width:2px
classDef awsProvider fill:#FFEBEE,stroke:#D32F2F,stroke-width:2px
classDef azureProvider fill:#E3F2FD,stroke:#1976D2,stroke-width:2px
classDef gcpProvider fill:#E8F5E9,stroke:#388E3C,stroke-width:2px
classDef account fill:#F3E5F5,stroke:#7B1FA2,stroke-width:2px
classDef region fill:#FFF3E0,stroke:#E65100,stroke-width:2px
classDef az fill:#E8EAF6,stroke:#3F51B5,stroke-width:2px
classDef subnet fill:#FFFDE7,stroke:#FBC02D,stroke-width:2px
class BaseCIDR baseCidr
class AWS,AWSProd,AWSDev,AWSStage,AWSUsEast,AWSUsWest,AWSUsEast1a,AWSUsEast1b,AWSUsWest2a,AWSUsWest2b,AWSPublic1,AWSPrivate1 awsProvider
class Azure,AzureProd,AzureDev,AzureStage,AzureEastUS,AzureWestUS,AzureEastUS1,AzureEastUS2,AzureWestUS1,AzureWestUS2,AzurePublic1,AzurePrivate1 azureProvider
class GCP,GCPProd,GCPDev,GCPStage,GCPUsEast,GCPUsWest,GCPUsEast1b,GCPUsEast1c,GCPUsWest1a,GCPUsWest1b,GCPPublic1,GCPPrivate1 gcpProvider
Multi-Cloud Hierarchical Allocation
Subnetter allows you to manage your IP space across different cloud providers with a hierarchical approach:
Base CIDR : Start with a single large CIDR block (e.g., 10.0.0.0/8)
Cloud Providers : Divide the base CIDR into non-overlapping blocks for each cloud provider
AWS: 10.0.0.0/12
Azure: 10.16.0.0/12
GCP: 10.32.0.0/12
Accounts : Allocate provider-specific CIDRs to different accounts
Production: 10.0.0.0/16 (AWS), 10.16.0.0/16 (Azure), 10.32.0.0/16 (GCP)
Development: 10.1.0.0/16 (AWS), 10.17.0.0/16 (Azure), 10.33.0.0/16 (GCP)
Staging: 10.2.0.0/16 (AWS), 10.18.0.0/16 (Azure), 10.34.0.0/16 (GCP)
Regions : For each account and provider, allocate CIDRs to regions
us-east-1: 10.0.0.0/20 (AWS)
eastus: 10.16.0.0/20 (Azure)
us-east1: 10.32.0.0/20 (GCP)
Availability Zones : Divide region CIDRs among AZs
us-east-1a: 10.0.0.0/22 (AWS)
eastus-1: 10.16.0.0/22 (Azure)
Subnets : Finally, create subnet CIDRs in each AZ based on type
Public: 10.0.0.0/24 (AWS), 10.16.0.0/24 (Azure)
Private: 10.0.1.0/24 (AWS), 10.16.1.0/24 (Azure)
Data: 10.0.2.0/24 (AWS)
Each step of this process is automated by Subnetter, ensuring consistent, non-overlapping CIDR allocation across your entire multi-cloud environment.
Quick Start
subnetter generate --config config.json --output allocations.csv
npx subnetter generate --config config.json --output allocations.csv
yarn global add subnetter
subnetter generate --config config.json --output allocations.csv
Documentation Overview
User Guide
Comprehensive guide covering installation, configuration, usage examples, and best practices.
Read the User Guide
Configuration Reference
Detailed schema reference for Subnetter configuration file format.
View Configuration Reference
API Documentation
Reference for developers using Subnetter programmatically in their Node.js applications.
Browse API Docs
Troubleshooting
Solutions for common issues encountered when using Subnetter.
Troubleshooting Guide
Key Resources
CIDR Primer
Learn about CIDR notation and IP subnetting concepts.
Read CIDR Primer
Architecture
Understand Subnetter’s technical design and components.
View Architecture
Developer Guide
Guidelines for contributing to the Subnetter codebase.
Developer Guide
Error Handling
Detailed information about error types, codes, and handling.
Error Handling