Migrate from Fastly to Azion

A platform migration usually begins long before the first service is cloned or the first domain is cut over. It starts when a team notices that delivery, compute, cache, security, and observability workflows are spread across too many configuration surfaces.

For teams using Fastly, this moment often appears after years of accumulated delivery logic: services with multiple origins, VCL snippets, Compute packages, dictionaries, cache overrides, TLS automation, WAF policies, logging endpoints, and inspector dashboards. Each layer may work independently, but the combined operational model can slow releases and make changes harder to validate.

For teams currently using Fastly Full-Site Delivery, Compute, Edge Data Storage, Object Storage, Image Optimizer, Fastly Next-Gen WAF, DDoS Protection, Bot Management, Platform TLS, High Volume Logging, Domain Inspector, Origin Inspector, or Log Explorer & Insights, Azion provides equivalent capabilities through Applications, Functions, KV Store, Object Storage, Image Processor, Firewall, Web Application Firewall, DDoS Protection, Bot Manager, Certificate Manager, Data Stream, Real-Time Events, and Real-Time Metrics.

The strongest reason to migrate is not simply to replace one vendor with another. It is to consolidate application delivery, compute, storage, security, and observability into a unified platform designed for globally distributed applications.

How Fastly to Azion Migration Works

Traditional platform migrations often require rewriting service logic, reconfiguring origins from scratch, and recreating security and logging behavior under pressure. This approach creates operational risk, extends timelines, and makes rollback harder.

The Azion migration approach preserves your application behavior while transitioning to a unified platform:

  1. Incremental migration path. Start with one representative Fastly service, validate delivery and security behavior on Azion, and expand to additional services only after the pattern is proven.

  2. Preserved application logic. Origins, cache policies, redirects, headers, security controls, and data access patterns map to Azion Applications, Rules Engine, Functions, Connectors, KV Store, and Object Storage with focused configuration changes.

  3. Unified platform model. Instead of managing delivery, compute, storage, security, and observability as disconnected products, Azion brings these capabilities together with consistent APIs, Console workflows, and deployment patterns.

Feature Mapping

The following table provides a comprehensive mapping of Fastly products and configuration areas to their Azion equivalents. A dash (-) indicates that Azion does not currently offer a direct equivalent.

Fastly Product or FeatureDescriptionAzion Equivalent
Full-Site DeliveryWebsite, application, API, and mobile delivery through Fastly services.Applications
Fastly servicesMain delivery resource for domains, origins, caching, request handling, and service versions.Applications + Workloads
DomainsHostnames associated with Fastly services.Workloads
Hosts and originsBackend origin configuration for Fastly delivery services.Connectors
Origin Shield / shielding patternsReduce origin traffic by routing cache misses through an intermediate shield location.Origin Shield + Tiered Cache
ConditionsRequest, cache, and response conditions in Fastly service configuration.Rules Engine for Applications
Request settingsRequest manipulation, forwarding, and handling behavior.Rules Engine for Applications + Functions
Response settingsResponse header and delivery behavior.Rules Engine for Applications
VCL snippets / custom VCLCustom delivery logic for redirects, headers, cache keys, origin selection, and request control.Rules Engine for Applications + Functions
ComputeServerless compute platform that runs custom code on Fastly’s network.Functions for Applications
Compute packagesPackaged application code deployed to Fastly Compute.Functions + Azion CLI
Edge Data StorageKey-value data used by Fastly Compute services.KV Store
Object StorageS3-compatible object storage integrated with delivery and compute services.Object Storage
Cache ReservationReserved cache capacity for content on Fastly.Cache + Tiered Cache
Cache APIsProgrammatic cache interaction patterns for Compute applications.Functions + Cache + Real-Time Purge
Streaming DeliveryDelivery of live and video-on-demand streaming content.Applications + Cache + Object Storage
Media Shield for LiveReduces origin traffic for live video workflows.Tiered Cache + Origin Shield
Media Shield for VODReduces origin traffic for video-on-demand workflows.Tiered Cache + Origin Shield
Image OptimizerReal-time image transformation and optimization service.Image Processor
WebSocketsLong-lived, bidirectional communication for real-time applications.WebSocket Proxy + WebSocket API
FanoutPublish-subscribe messaging patterns on Fastly.Functions + WebSocket Proxy
AI AcceleratorSemantic caching and traffic acceleration for generative AI APIs.AI Inference + Cache
Fastly Next-Gen WAFWeb application firewall for suspicious traffic detection and application protection.Web Application Firewall
Edge Rate LimitingCount requests and apply actions when limits are exceeded.Rules Engine for Firewall + Functions for Firewall
Fastly DDoS ProtectionDDoS visibility and mitigation.DDoS Protection + Network Shield
Bot ManagementDetect and respond to automated traffic.Bot Manager + Bot Manager Lite
CertainlyFastly certificate authority for TLS certificates.Certificate Manager
Platform TLSAPI-driven TLS certificate and key management.Certificate Manager + Azion API
TLS Service OptionsTLS configuration for serving sites and applications over HTTPS.Certificate Manager + Workloads
High Volume LoggingReal-time log streaming to external destinations.Data Stream
Log Explorer & InsightsInspect and monitor log data on the Fastly platform.Real-Time Events
Domain InspectorDomain-level traffic visibility and reporting.Real-Time Metrics
Origin InspectorOrigin response visibility and reporting.Real-Time Metrics + Real-Time Events
Observability featuresTraffic, security, performance, and origin visibility.Real-Time Metrics + Real-Time Events + Data Stream
Fastly APIProgrammatic management of Fastly resources.Azion API
Fastly CLICommand-line workflow for Fastly services and Compute projects.Azion CLI
Fastly Terraform ProviderInfrastructure as Code for Fastly resources.Terraform Provider

Migration Strategy

The migration is organized around Azion’s four product categories, allowing teams to plan and execute each layer independently:

  • Build: migrate delivery services, origins, VCL behavior, Compute code, cache policies, image optimization, streaming, WebSocket, and AI acceleration patterns.
  • Secure: migrate domains, certificates, WAF policies, DDoS protection, bot controls, and rate limiting.
  • Store: migrate object storage and edge key-value data to Object Storage and KV Store.
  • Observe: migrate logging, inspectors, metrics, dashboards, and external log destinations to Azion’s real-time observability stack.

Build

The Build category covers application deployment, delivery configuration, compute, routing, cache, and media optimization. Start here to recreate the application behavior users see before moving security, data, and observability layers.

1. Project Setup on Azion

The first step brings your application into Azion in a way that is familiar to teams that already manage Fastly services and Compute projects. If you have used Fastly service versions, Compute packages, and CLI deployments, you already understand the pattern: define configuration, deploy a version, validate behavior, and promote traffic when ready.

Azion follows a similar workflow but consolidates application delivery, Functions, rules, security, and observability in the same platform context.

Key Differences

AspectFastlyAzion
Primary delivery resourceServiceApplication + Workload
Config filefastly.toml, VCL, service version configazion.config.js and Console configuration
Compute deploymentCompute packageFunction + Function Instance
Routing and behaviorVCL, conditions, request/response settingsRules Engine + Functions
ObservabilityInspectors, logging endpoints, Log ExplorerReal-Time Metrics, Real-Time Events, Data Stream

Connect Your Repository

  1. Open Azion Console.
  2. Click + Create > Import from GitHub.
  3. Authorize the Azion GitHub App.
  4. Select the repository you want to migrate.

Configure Your Build

Azion auto-detects your framework and configures build settings. Override the detected preset in azion.config.js:

import { defineConfig } from 'azion'
export default defineConfig({
name: 'my-fastly-migration',
preset: 'nextjs', // Override auto-detection if needed
})

Deploy and Verify

Deploy from the Azion Console or CLI. Your temporary Azion URL follows this pattern:

https://xxxxxxxxxx.map.azionedge.net/

Validate the deployment before moving production domains:

Terminal window
curl -I https://xxxxxxxxxx.map.azionedge.net/
curl https://xxxxxxxxxx.map.azionedge.net/health

Reference documentation

2. Converting Service and Build Configuration

A migration can appear successful when the first request returns 200, but fail later when cache behavior, redirects, headers, or origin routing differs from Fastly. Review service configuration carefully instead of treating the migration as a simple command replacement.

CLI Quick Reference

TaskFastly CLIAzion CLI
Installbrew install fastly/tap/fastlycurl -fsSL https://cli.azion.app/install.sh | bash
Loginfastly profile createazion login
Local devfastly compute serveazion dev
Deployfastly compute publish or service activationazion deploy
View logsFastly logging endpoint or Log Explorerazion logs
Purgefastly purgeazion purge

Configuration Inventory

Before recreating the service in Azion, inventory:

  • Active Fastly services and service versions
  • Domains and TLS certificates
  • Origins, shielding, health checks, and failover logic
  • Cache settings, cache keys, stale behavior, and purge workflows
  • Conditions, VCL snippets, custom VCL, and request/response settings
  • Compute packages and language runtimes
  • Dictionaries, Config Store data, Secret Store values, and Edge Data Storage
  • WAF policies, bot controls, DDoS protections, and rate limits
  • Logging endpoints, inspector dashboards, and alert dependencies

Reference documentation

3. Migrating Environment Variables and Secrets

Environment variables and secrets contain API keys, origin credentials, feature flags, third-party endpoints, and operational settings. Migrating them incorrectly causes runtime failures even when deployment succeeds.

Key Differences

AspectFastlyAzion
Compute accessLanguage-specific environment or secret APIsAzion.env.get('VARIABLE')
Configuration dataDictionaries, Config Store, Secret StoreVariables, KV Store, Function Instances
Runtime scopeService or Compute package contextFunction instance and application context

Evaluate Your Variables

Before changing code, identify every variable in:

  • fastly.toml and Compute project configuration
  • Fastly dictionaries and Config Store entries
  • Fastly Secret Store values
  • CI/CD environment settings
  • Runtime configuration in source code

Create Variables in Azion

  1. Access Azion Console.
  2. Navigate to Build > Variables.
  3. Click Add Variable.
  4. Enter the variable name and value.
  5. Click Save.

Update Your Code

// Before: Fastly Compute style configuration access varies by runtime
const apiKey = process.env.API_KEY;
// After: Azion Functions
const apiKey = Azion.env.get('API_KEY');

Reference documentation

4. Migrating Full-Site Delivery to Applications

Fastly Full-Site Delivery services deliver websites, applications, APIs, and mobile traffic through domains, origins, cache rules, and custom delivery logic. Azion Applications provide equivalent delivery capabilities with integrated Rules Engine, Cache, Functions, and Connectors.

Key Differences

AspectFastly Full-Site DeliveryAzion Applications
Delivery resourceService and service versionApplication
DomainsService domainsWorkloads and custom domains
OriginsHosts and backendsConnectors
Behavior logicConditions, request/response settings, VCLRules Engine and Functions
Cache controlCache settings, VCL, surrogate keysCache Settings, Rules Engine, Real-Time Purge

Configuration Steps

  1. Access Azion Console.
  2. Navigate to Build > Applications.
  3. Click Add Application.
  4. Configure your Main Settings.
  5. Create Connectors for each Fastly origin.
  6. Configure Cache Settings and Rules Engine.
  7. Add custom domains through Workloads when ready for cutover.

Service Configuration Migration

import { defineConfig } from 'azion'
export default defineConfig({
name: 'fastly-service-migration',
applications: [{
name: 'main-app',
origins: [{
name: 'primary-origin',
type: 'http',
addresses: [{
address: 'origin.example.com',
weight: 1
}]
}],
cache: {
ttl: 3600,
staleWhileRevalidate: 300
},
rules: {
request: [{
name: 'API routes bypass cache',
criteria: [{
variable: 'uri',
operator: 'starts_with',
argument: '/api/'
}],
behavior: {
bypassCache: true,
setOrigin: 'primary-origin'
}
}]
}
}]
})

Reference documentation

5. Migrating VCL, Conditions, and Headers

Fastly services often contain business-critical behavior in VCL snippets, conditions, and request or response settings. Migrate simple rules to Rules Engine and reserve Functions for behavior that needs code.

Key Differences

AspectFastlyAzion
Simple redirectsVCL or request settingsRules Engine redirect behavior
Header changesVCL, response settingsRules Engine request/response behavior
Origin selectionVCL backend selectionRules Engine + Connectors
Complex logicCustom VCL or ComputeFunctions
Pattern matchingConditions and VCL expressionsRules Engine criteria and regex

Redirect Migration Example

# Fastly VCL pattern
if (req.url.path ~ "^/old/(.*)$") {
set req.http.Location = "/new/" + re.group.1;
error 750 "Moved Permanently";
}
# Azion Rules Engine
Criteria: ${uri} matches ^/old/(.*)$
Behavior: Redirect To (301): /new/%{capture[1]}

Security Header Migration Example

import type { AzionConfig } from 'azion/config';
const config: AzionConfig = {
applications: [{
name: 'my-app',
rules: {
response: [{
name: 'Security Headers',
active: true,
criteria: [{
variable: 'uri',
conditional: 'if',
operator: 'starts_with',
argument: '/'
}],
behavior: {
addResponseHeader: [
'X-Frame-Options: SAMEORIGIN',
'X-Content-Type-Options: nosniff'
]
}
}]
}
}]
};
export default config;

Migration Checklist

  • Convert path-based conditions to Rules Engine criteria.
  • Move simple header additions to response rules.
  • Move request header normalization to request rules.
  • Rebuild origin selection with Connectors and Rules Engine.
  • Use Functions only when conditions require code, external lookups, signed tokens, or custom algorithms.

Reference documentation

6. Migrating Compute to Functions

Fastly Compute services run packaged code on Fastly’s network. Azion Functions provide distributed JavaScript execution for request handling, API orchestration, personalization, redirects, authentication, and integration logic.

Key Differences

AspectFastly ComputeAzion Functions
Deployment unitCompute packageFunction and Function Instance
Runtime modelWebAssembly-based runtimesJavaScript runtime
Function signatureRuntime-specific request handlerexport default { async fetch(request) {} }
Environment accessRuntime-specific environment APIsAzion.env.get('VARIABLE')
Platform data accessEdge Data Storage, Config Store, Secret StoreKV Store, Object Storage, Variables

Update Function Signature

// Before: Fastly Compute JavaScript style
addEventListener('fetch', (event) => {
event.respondWith(handleRequest(event.request));
});
async function handleRequest(request) {
const url = new URL(request.url);
return new Response('Path: ' + url.pathname, {
status: 200,
headers: { 'Content-Type': 'text/plain' }
});
}
// After: Azion Functions
export default {
async fetch(request) {
const url = new URL(request.url);
return new Response('Path: ' + url.pathname, {
status: 200,
headers: { 'Content-Type': 'text/plain' }
});
}
};

Update Configuration Access

// Before: Fastly Compute configuration access varies by runtime
const apiToken = process.env.API_TOKEN;
// After: Azion Functions
const apiToken = Azion.env.get('API_TOKEN');

Non-JavaScript Compute Code

Fastly Compute projects written in Rust, Go, or other WebAssembly-targeted languages must be rewritten in JavaScript for Azion Functions. During the rewrite, separate generic business logic from platform-specific APIs:

Code AreaMigration Guidance
Request parsingUse the standard Request and URL APIs.
Response creationUse the standard Response API.
HeadersUse request.headers and response headers.
Environment valuesUse Azion.env.get().
Key-value dataUse Azion.KV.
External servicesUse fetch().

Reference documentation

7. Migrating Load Balancing and Origin Failover

Fastly origin configuration can include multiple backends, shielding, health checks, and failover logic. Azion uses Connectors, Load Balancer, and Rules Engine to recreate origin routing and availability behavior.

Key Differences

AspectFastlyAzion
Origin resourceBackend or hostConnector
Health checksBackend health checksConnector health checks
FailoverVCL or service settingsLoad Balancer and Rules Engine
Origin shieldingShieldingOrigin Shield and Tiered Cache
Weighted originsBackend selection logicLoad Balancer address weights

Configuration Steps

  1. Access Azion Console.
  2. Go to Products menu > Connectors.
  3. Create a Connector for each origin server.
  4. Configure health checks.
  5. Configure origin weights and failover behavior.
  6. Associate Connectors with your Application rules.

Reference documentation

8. Migrating Cache Configuration

Caching configuration determines how content is stored, revalidated, and purged. Fastly cache behavior often combines service settings, VCL, surrogate keys, cache overrides, and purge APIs. Azion provides Cache Settings, Rules Engine, Tiered Cache, and Real-Time Purge.

Key Differences

AspectFastly CacheAzion Cache
Cache policyService settings, VCL, cache overridesCache Settings and Rules Engine
Cache keyVCL and cache configurationAdvanced Cache Key
ShieldingShield POPTiered Cache and Origin Shield
PurgeURL, surrogate key, service purgeURL, Cache Key, Wildcard purge
Stale contentVCL and stale settingsStale-while-revalidate settings

Configuration Steps

  1. Access Azion Console.
  2. Edit your Application.
  3. Navigate to Cache Settings.
  4. Configure default cache TTL.
  5. Enable Tiered Cache when origin load reduction is required.
  6. Add custom cache rules through Rules Engine.

Fastly Purge to Azion Purge

Terminal window
# Before: Fastly purge by URL
fastly purge --service-id SERVICE_ID https://www.example.com/images/logo.png
# After: Azion purge by URL
curl -X POST 'https://api.azion.com/v4/workspace/purge/url' --header 'Authorization: Token YOUR_TOKEN' --header 'Content-Type: application/json' --data '{
"items": ["https://www.example.com/images/logo.png"],
"layer": "cache"
}'
# After: Azion purge by wildcard
curl -X POST 'https://api.azion.com/v4/workspace/purge/wildcard' --header 'Authorization: Token YOUR_TOKEN' --header 'Content-Type: application/json' --data '{
"items": ["https://www.example.com/images/*"],
"layer": "cache"
}'

Reference documentation

9. Migrating Image Optimizer to Image Processor

Image optimization reduces file sizes while preserving visual quality. Azion Image Processor transforms, optimizes, and delivers images from distributed locations using URL parameters and application configuration.

Key Differences

AspectFastly Image OptimizerAzion Image Processor
TransformationsReal-time image transformationsResize, crop, fit, format optimization
URL formatQuery parameters or configured image options?ims=<OPTIONS> query parameter
Format supportOptimized image formatsWebP, AVIF, JPEG, PNG
Delivery pathFastly serviceAzion Application with Image Processor
Storage sourceOrigin or object storageHTTP origin or Object Storage

Configuration Steps

  1. Access Azion Console.
  2. Edit your Application.
  3. Navigate to Image Processor settings.
  4. Enable Image Processor.
  5. Configure default quality and format behavior.
  6. Validate representative image URLs before cutover.

URL Format Comparison

# Fastly image transformation patterns vary by implementation
https://www.example.com/image.jpg?width=400&quality=85
# Azion Image Processor
https://www.example.com/image.jpg?ims=400x400

Transformation Parameters

SyntaxDescriptionExample
?ims=WxHResize to width x height?ims=400x300
?ims=WxResize to width with automatic height?ims=400x
?ims=xHResize to height with automatic width?ims=x300
?ims=WxH:fillCrop to exact dimensions?ims=400x300:fill
?ims=WxH:fitFit within dimensions?ims=400x300:fit

Reference documentation

10. Migrating Streaming, Media Shield, WebSockets, and Fanout

Fastly streaming, Media Shield, WebSocket, and Fanout patterns are used for bandwidth-heavy and real-time workloads. Migrate each pattern based on the traffic model: cacheable media, long-lived connections, or publish-subscribe behavior.

Capability Mapping

Fastly CapabilityAzion Migration Path
Streaming DeliveryApplications + Cache + Object Storage
Media Shield for LiveTiered Cache + Origin Shield
Media Shield for VODTiered Cache + Origin Shield
WebSocketsWebSocket Proxy + WebSocket API
FanoutFunctions + WebSocket Proxy + external pub/sub service when needed

WebSocket Migration Checklist

  1. Enable WebSocket support on the target Application.
  2. Confirm the origin accepts Upgrade: websocket and Connection: upgrade headers.
  3. Validate that application routes do not apply cache or image processing to WebSocket traffic.
  4. Test successful upgrades with 101 Switching Protocols responses.
  5. Monitor WebSocket events and errors after cutover.

WebSocket Function Example

export default {
async fetch(request) {
if (request.headers.get('upgrade') === 'websocket') {
const { response, socket } = upgradeWebSocket(request);
socket.addEventListener('message', (event) => {
socket.send('received: ' + event.data);
});
return response;
}
return new Response('Expected WebSocket upgrade', { status: 400 });
}
};

Reference documentation

11. Migrating AI Accelerator Patterns

Fastly AI Accelerator focuses on semantic caching and acceleration for AI API traffic. On Azion, AI workloads can combine AI Inference, Functions, Cache, Real-Time Events, and Data Stream depending on whether the goal is inference execution, traffic control, observability, or response caching.

Key Differences

AspectFastly AI AcceleratorAzion
Primary patternSemantic caching for AI API trafficAI Inference + Functions + Cache
Request controlService and Compute logicRules Engine + Functions
ObservabilityLogging and inspectorsReal-Time Events + Data Stream + Real-Time Metrics
Model executionExternal AI APIs accelerated by FastlyAI Inference or external AI APIs called from Functions

Function Integration Example

export default {
async fetch(request) {
const prompt = await request.text();
const response = await fetch('https://ai-provider.example.com/v1/chat/completions', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer ' + Azion.env.get('AI_API_KEY')
},
body: JSON.stringify({ prompt })
});
return response;
}
};

Reference documentation

Secure

The Secure category covers domains, certificates, firewall rules, bot controls, DDoS protection, and rate limiting. Plan these migrations as controlled cutovers because they affect how users reach your application and how traffic is protected in production.

1. Migrating Custom Domains

Custom domain migration is one of the most sensitive parts of any platform transition. It affects users, SEO, brand trust, and production availability. Plan domain migration as a controlled cutover, not a last-minute DNS change.

Migration Strategies

StrategyBest ForDNS Control
CNAMEQuick subdomain migrationKeep your DNS provider
NameserverFull DNS control and apex domainsTransfer DNS to Azion

Create the Certificate

Create your SSL/TLS certificate before pointing your domain to Azion. This ensures users can access the application securely over HTTPS when the domain starts resolving to the new infrastructure.

Azion provides free Let’s Encrypt certificates with automatic renewal.

Configure the Domain

Create a workload in Azion Console and associate your custom domain. See Workloads Documentation.

Point the Domain to Azion

Point the subdomain to the Azion-generated domain:

www CNAME xxxxxxxxxx.map.azionedge.net

This keeps your current DNS provider while routing traffic through Azion.

Verify Propagation

Terminal window
dig www.yourdomain.com CNAME +short
curl -I https://www.yourdomain.com/

Reference documentation

2. Migrating TLS to Certificate Manager

Fastly Platform TLS, TLS Service Options, and Certainly-backed workflows manage certificates and HTTPS service behavior. Azion Certificate Manager manages Let’s Encrypt, custom certificates, Azion SAN certificates, and Trusted CA certificates for mTLS scenarios.

Key Differences

AspectFastly TLSAzion Certificate Manager
Managed certificatesPlatform TLS and Certainly workflowsLet’s Encrypt and Azion SAN certificates
Custom certificatesUpload or API-managed certificatesUpload custom certificates and private keys
AutomationFastly APIConsole and Azion API
mTLSFastly TLS and security configurationTrusted CA certificates and mTLS configuration
AssociationFastly service/domainWorkload or domain association

Custom Certificate Upload

  1. Go to Products menu > Certificate Manager.
  2. Click + Certificate.
  3. Select Custom Certificate.
  4. Upload your certificate in PEM format.
  5. Upload your private key.
  6. Upload the intermediate CA chain if applicable.
  7. Associate the certificate with your workload.

Reference documentation

3. Migrating Fastly Next-Gen WAF to Web Application Firewall

Web Application Firewall protects applications from malicious traffic, SQL injection, cross-site scripting, and other application-layer attacks. Migrating WAF rules requires careful mapping of rule logic, match conditions, and enforcement modes.

Key Differences

AspectFastly Next-Gen WAFAzion WAF
Managed protectionNext-Gen WAF rules and signalsWAF Rule Sets
Custom logicWAF rules and conditionsRules Engine for Firewall
ActionsAllow, block, log, challenge patternsAllow, deny, drop, redirect, custom HTML, hold connection
TuningSignal exclusion and thresholdsLearning and Blocking modes, sensitivity settings
AssociationService or domain scopeFirewall associated with workloads

Migration Steps

  1. Access Azion Console.
  2. Go to Products menu > Firewall.
  3. Select or create a Firewall instance.
  4. Navigate to WAF.
  5. Enable the desired managed rule sets.
  6. Configure sensitivity per rule set.
  7. Create custom rules in Rules Engine.
  8. Associate the Firewall with your workload.

Rule Migration Example

# Fastly-style intent
Block requests to /admin unless the client IP is in an approved network.
# Azion criteria
Variable: ${uri}
Operator: matches
Argument: /admin
AND
Variable: ${remote_addr}
Operator: does not match
Argument: 10.0.0.0/8
Behavior: Deny (403)

Reference documentation

4. Migrating DDoS Protection

DDoS protection guards against volumetric attacks, protocol attacks, and application-layer floods. Azion provides automatic DDoS protection and Network Shield capabilities for network-layer controls.

Key Differences

AspectFastly DDoS ProtectionAzion DDoS Protection
ActivationProduct and service configurationAutomatic protection with configurable security controls
Layer coverageNetwork and application-layer mitigationL3, L4, and L7 protection patterns
CustomizationFastly security controlsFirewall, Network Shield, Rules Engine
VisibilityFastly security dashboards and logsReal-Time Metrics, Real-Time Events, Data Stream

Migration Steps

  1. Document current Fastly DDoS assumptions, support processes, and escalation paths.
  2. Confirm the Azion workload, Firewall, and Network Shield configuration.
  3. Recreate application-layer controls using Rules Engine for Firewall.
  4. Validate observability through Real-Time Metrics, Real-Time Events, and Data Stream.
  5. Keep rollback and escalation procedures ready during the cutover window.

Reference documentation

5. Migrating Bot Management

Bot management protects applications from automated abuse while allowing legitimate bots. Azion Bot Manager provides detection and response controls, and Bot Manager Lite is available through Marketplace for simpler use cases.

Key Differences

AspectFastly Bot ManagementAzion Bot Manager
DetectionBot signals and behaviorMachine learning, behavioral analysis, fingerprinting, reputation intelligence
ActionsAllow, block, challenge patternsAllow, deny, drop, redirect, custom HTML, random delay, hold connection
Lite optionPlan-dependent Fastly featuresBot Manager Lite from Marketplace
Rule integrationFastly security configurationFirewall Rules Engine

Custom Bot Rules

Criteria: ${user_agent} contains "BadBot"
Behavior: Deny (403)
Criteria: ${user_agent} contains "Googlebot"
Behavior: Allow

Verification

Terminal window
curl -A "BadBot/1.0" https://yourdomain.com/
curl -A "Mozilla/5.0" https://yourdomain.com/

Reference documentation

6. Migrating Edge Rate Limiting

Rate limiting protects applications from abuse by limiting request rates per client, route, method, token, or custom key. Recreate Fastly rate limiting behavior with Firewall rules and Functions where custom counters or logic are required.

Key Differences

AspectFastly Edge Rate LimitingAzion Rate Limiting Pattern
ConfigurationFastly rate limiting controlsFirewall Rules Engine + Functions
GranularityClient, route, service-specific keysIP, path, method, headers, custom logic
ActionsBlock or penalize clientsDeny, drop, redirect, custom response
Custom countersFastly controls or Compute logicFunctions + KV Store

Firewall-Based Rate Limiting

Terminal window
curl -X POST 'https://api.azionapi.net/v4/workspace/firewalls/{firewall_id}/request_rules' --header 'Authorization: Token YOUR_TOKEN' --header 'Content-Type: application/json' --data '{
"name": "Rate Limit API",
"criteria": [[{"variable": "${uri}", "operator": "starts_with", "argument": "/api/"}]],
"behaviors": [
{"type": "rate_limit", "attributes": {"rps": 100, "window": 60, "action": "block"}}
]
}'

Reference documentation

Store

The Store category covers data services. Migrate object and key-value data with attention to consistency, access patterns, object naming, permissions, and application compatibility.

1. Migrating Fastly Object Storage to Object Storage

Object storage powers files that matter to users and business operations: images, documents, static assets, media files, uploads, and generated content. Azion Object Storage is S3-compatible and can be used as an origin for Applications.

Key Differences

AspectFastly Object StorageAzion Object Storage
ProtocolS3-compatible workflowsS3 standard
EndpointFastly object storage endpoints3.us-east-005.azionstorage.net
Delivery pathFastly delivery servicesApplications + Connectors
Object managementS3-compatible toolsS3-compatible tools, API, CLI, Runtime API
End-user deliveryDelivery serviceApplication with Object Storage Connector

Update Configuration

import { S3Client } from '@aws-sdk/client-s3';
const client = new S3Client({
region: 'us-east-005',
endpoint: 'https://s3.us-east-005.azionstorage.net',
credentials: {
accessKeyId: Azion.env.get('AZION_ACCESS_KEY'),
secretAccessKey: Azion.env.get('AZION_SECRET_KEY')
}
});

Migrate Data with S3-Compatible Tools

Use tools such as s3cmd, rclone, or AWS CLI to move objects:

TaskCommand Pattern
List bucketss3cmd ls
Upload objects3cmd put file.png s3://my-bucket/
Download objects3cmd get s3://my-bucket/file.png
Sync bucketss3cmd sync s3://source-bucket/ s3://dest-bucket/

Reference documentation

2. Migrating Edge Data Storage to KV Store

Fastly Edge Data Storage and related key-value patterns are commonly used for configuration, feature flags, personalization, authorization metadata, and lightweight state. Azion KV Store provides distributed key-value storage accessible from Functions.

Key Differences

AspectFastly Edge Data StorageAzion KV Store
Data modelKey-value containersNamespaces with key-value pairs
Access patternCompute accessFunctions through Azion.KV
Common use casesConfig, flags, session metadataConfig, flags, session metadata, lightweight state
Consistency planningApplication dependentPlan for distributed key-value behavior

API Comparison

// Before: Fastly data access varies by product and runtime
const value = await edgeData.get('feature:checkout');
await edgeData.put('feature:checkout', 'enabled');
// After: Azion KV Store
const kv = await Azion.KV.open('my-namespace');
const value = await kv.get('feature:checkout');
await kv.put('feature:checkout', 'enabled');

Create a KV Store Namespace

  1. Access Azion Console.
  2. Go to Store > KV Store.
  3. Create a namespace for the migrated data.
  4. Import or recreate keys using your migration script.
  5. Update Functions to use the namespace name.

Migration Checklist

  • Export keys, values, metadata, and expiration rules from Fastly.
  • Preserve key prefixes and naming conventions where possible.
  • Document default behavior for missing keys.
  • Validate value encoding, JSON serialization, and binary data handling.
  • Test read and write paths before moving production traffic.

Reference documentation

Observe

The Observe category covers metrics, events, logs, and external streaming destinations. Migrating observability ensures you keep production visibility, troubleshooting capability, and compliance reporting after cutover.

1. Migrating Domain and Origin Inspector to Real-Time Metrics

Fastly Domain Inspector and Origin Inspector provide traffic and origin visibility. Azion Real-Time Metrics provides dashboards and GraphQL access for requests, bandwidth, status codes, latency, cache, and origin behavior.

Key Differences

AspectFastly InspectorsAzion Real-Time Metrics
ScopeDomain and origin reportingApplication, workload, cache, performance, and traffic metrics
Access methodFastly UI and APIsConsole and GraphQL API
Use casesTraffic trends, origin performanceTraffic trends, latency, cache hit ratio, errors, origin behavior
Migration focusDashboard and alert parityDashboard, filters, GraphQL queries, Grafana if needed

Available Metrics

Azion Real-Time Metrics tracks:

  • Request metrics: total requests, requests by status code, requests by HTTP method
  • Performance metrics: response time, upstream header time, origin response time
  • Bandwidth metrics: data transferred and data saved by cache
  • Cache metrics: hit ratio, miss ratio, expired objects
  • Error metrics: 4xx errors, 5xx errors, origin errors

Access Real-Time Metrics

  1. Access Azion Console.
  2. Go to Products menu > Real-Time Metrics.
  3. Select your application or workload.
  4. Configure the time range and filters.
  5. Export or recreate dashboards if needed.

Reference documentation

2. Migrating Log Explorer & Insights to Real-Time Events

Log data is essential for debugging, security analysis, and compliance. Real-Time Events provides immediate log access through Console or GraphQL API for troubleshooting and investigation.

Key Differences

AspectFastly Log Explorer & InsightsAzion Real-Time Events
Access methodFastly UIConsole and GraphQL API
Data modelFastly log fieldsHTTP, WAF, DNS, Functions, image, and other event datasets
QueryingExplorer filtersConsole filters and GraphQL
Use casesDebugging and security investigationDebugging, security investigation, compliance evidence

Access Real-Time Events

  1. Access Azion Console.
  2. Go to Products menu > Real-Time Events.
  3. Select the dataset, such as HTTP Requests or WAF.
  4. Configure the time range and filters.
  5. Click Search to query logs.
  6. Click a row to inspect event details.

Reference documentation

3. Migrating High Volume Logging to Data Stream

Fastly High Volume Logging exports logs to downstream destinations. Azion Data Stream exports logs continuously to external destinations for long-term storage, analytics, SIEM, and operational monitoring.

Key Differences

AspectFastly High Volume LoggingAzion Data Stream
Delivery modelLog streaming to configured endpointsPush to external destinations
FormatEndpoint-specific log formatsJSON and customizable templates
DestinationsExternal logging and storage servicesS3, Azure Blob, Datadog, Splunk, Kafka, BigQuery, Elasticsearch, HTTP endpoints, and more
Source selectionFastly service logsApplications, WAF, Functions, and other event sources

Configure Data Stream

  1. Access Azion Console.
  2. Go to Products menu > Data Stream.
  3. Click + Stream.
  4. Configure the source, such as Applications or WAF.
  5. Select or create a template for the log format.
  6. Choose a destination.
  7. Configure destination credentials.
  8. Activate the stream.

Supported Destinations

Data Stream supports multiple destination patterns:

  • Cloud Storage: Amazon S3, Azure Blob Storage, Azion Object Storage
  • Monitoring: Datadog, Splunk, Elasticsearch, Azure Monitor
  • Streaming: AWS Kinesis Data Firehose, Apache Kafka
  • Analytics: Google BigQuery
  • Security: IBM QRadar
  • Custom: HTTP Webhook, Standard HTTP/HTTPS POST

Reference documentation

Troubleshooting

Common Issues

IssueLikely CauseSolution
Application responds differently from FastlyRules, VCL, cache key, or origin selection was not fully mappedCompare Fastly service version behavior with Azion Rules Engine and Connector configuration
Environment variables not foundVariables were not configured on the Function instanceConfirm variables exist and code uses Azion.env.get()
Redirects not workingVCL pattern was converted to an incorrect regexTest capture groups and verify Rules Engine criteria
Headers missingResponse settings or VCL header logic was not migratedAdd response rules or a Function for dynamic headers
Cache hit ratio dropsCache key, TTL, or shielding behavior changedReview Cache Settings, Advanced Cache Key, Tiered Cache, and Origin Shield
Compute code failsRuntime-specific Fastly APIs remain in the codeRewrite platform APIs using Azion Functions and Runtime APIs
KV data missingEdge Data Storage export or import was incompleteRe-export keys, validate namespaces, and check value encoding
Object Storage access deniedS3 credentials or endpoint are incorrectVerify credentials and use s3.us-east-005.azionstorage.net
WebSocket upgrade failsUpgrade headers or application module configuration are missingConfirm Upgrade and Connection headers and validate 101 Switching Protocols
Logs missing in destinationData Stream source, template, or endpoint is misconfiguredValidate stream status, destination credentials, and selected variables
Certificate not activeDomain ownership or certificate association is incompleteConfirm certificate status and workload association before DNS cutover

Key Advantages After Migration

Migrating from Fastly to Azion is strongest when the team treats the first cutover as a repeatable migration pattern. The immediate goal is continuity: users keep reaching the same domains, critical routes continue working, security controls remain active, and observability is ready before traffic moves.

The larger value comes after migration, when teams operate delivery, compute, storage, security, and observability in one platform model.

AreaAdvantage after migrationWhat it means in practice
Migration strategyIncremental migration pathTeams can migrate one Fastly service at a time and validate each layer independently.
Platform modelUnified application platformBuild, Secure, Store, and Observe capabilities are managed through a connected platform model.
BuildModern application deploymentApplications can be deployed from GitHub or CLI with Azion configuration.
BuildRules-based application controlRules Engine can manage redirects, headers, cache behavior, routing, and request/response logic.
BuildDistributed function executionFunctions can replace Compute logic that controls authentication, personalization, APIs, and integrations.
BuildIntegrated cache and origin protectionCache, Tiered Cache, Origin Shield, and Application Accelerator reduce origin dependency.
BuildImage optimization at delivery timeImage Processor transforms and optimizes images through URL parameters and application configuration.
SecureControlled domain and TLS cutoverWorkloads, Edge DNS, and Certificate Manager can be prepared before switching production traffic.
SecureIntegrated application securityWAF, Bot Manager, Network Shield, rate limiting patterns, and Firewall rules can protect workloads together.
StoreS3-compatible Object StorageFastly Object Storage workflows can be migrated using familiar S3-compatible tools and SDKs.
StoreKV for low-latency application dataEdge Data Storage use cases can be migrated to KV Store for configuration, flags, metadata, and lightweight state.
ObserveReal-time metrics for production visibilityReal-Time Metrics replaces inspector-style views with dashboards and GraphQL access.
ObserveReal-time events for investigationReal-Time Events provides detailed logs for requests, functions, WAF, DNS, image processing, and other datasets.
ObserveData streaming to external toolsData Stream sends logs to external destinations for SIEM, analytics, storage, and compliance workflows.

With Azion, teams can build and run applications on globally distributed infrastructure while combining compute, delivery, storage, security, and observability capabilities in one environment. This reduces the fragmentation that often appears when modern applications depend on many separate services and configuration patterns.

Next Steps

After your migration is complete:

Get Started with a Small Service

The best way to begin is not with the most complex Fastly service in your portfolio. Start with a service that is meaningful enough to validate the migration path, but small enough to move quickly and safely.

Choose a service that includes representative pieces of your architecture: one or two domains, a few origins, cache rules, redirects, headers, maybe one Compute package, and one logging destination. Use that service to validate the workflow, document the process, and identify internal patterns your team can reuse.

From there, expand gradually. Migrate more complex VCL. Move additional Compute services. Bring over storage and key-value data. Add observability. Review security rules. Then prepare production cutovers with greater confidence.

Need Help?

Get help from the Azion Support team, or join our Discord community to see how others are using Azion.