# How we saved 100 terabytes of memory by optimizing 1.1.1.1's DNS cache

DevFeed: [How we saved 100 terabytes of memory by optimizing 1.1.1.1's DNS cache](<https://devfeed.tech/articles/how-we-saved-100-terabytes-of-memory-by-optimizing-1-1-1-1-s-dns-cache-114.md>)

Original publisher: [Read original article](<https://blog.cloudflare.com/dns-cache-memory-optimization-1111/>)

Author: Sebastiaan Neuteboom

Published: 2026-08-27T17:02:35Z

Content type: article

Language: en

Sources: [Cloudflare Blog](<https://devfeed.tech/sources/cloudflare-blog.md>)

Topics: [Cache](<https://devfeed.tech/topics/cache.md>), [Caching](<https://devfeed.tech/topics/caching.md>), [Cloudflare](<https://devfeed.tech/topics/cloudflare.md>), [Rust](<https://devfeed.tech/topics/rust.md>), [benchmarking](<https://devfeed.tech/topics/benchmarking.md>), [Latency](<https://devfeed.tech/topics/latency.md>), [datacenter](<https://devfeed.tech/topics/datacenter.md>)

Tags: [1-1-1-1](<https://devfeed.tech/tags/1-1-1-1.md>), [benchmarking](<https://devfeed.tech/tags/benchmarking.md>), [cache](<https://devfeed.tech/tags/cache.md>), [cloudflare](<https://devfeed.tech/tags/cloudflare.md>), [data-center](<https://devfeed.tech/tags/data-center.md>), [deep-dive](<https://devfeed.tech/tags/deep-dive.md>), [dns](<https://devfeed.tech/tags/dns.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [latency](<https://devfeed.tech/tags/latency.md>), [memory](<https://devfeed.tech/tags/memory.md>), [net-maui](<https://devfeed.tech/tags/net-maui.md>), [optimization](<https://devfeed.tech/tags/optimization.md>), [performance](<https://devfeed.tech/tags/performance.md>), [rust](<https://devfeed.tech/tags/rust.md>)

## AI overview

Cloudflare describes five Rust-level changes to the memory layout of Big Pineapple, the platform behind 1.1.1.1 and other DNS services. The changes reduced DNS cache entry size by over 50%, freed roughly 100 terabytes of memory across the fleet, increased insert throughput by 43%, and reduced lookup latency by 19%.

## Source excerpt

Five Rust-level memory optimizations to the DNS cache layout of Big Pineapple cut per-entry memory by 56%, freeing approximately 100 TB of memory across Cloudflare's fleet.