---
title: "The search for speed in Figma"
description: "Figma's search slowness traced mostly to its own stack, not OpenSearch: OpenSearch's headline 8 ms metric was per-shard time, and only the \"took\" field in responses reveals overall query latency, which accounted for under 30% of API time."
url: "https://swe.quest/articles/the-search-for-speed-in-figma-06e4c11289fe0686"
canonical: "https://www.figma.com/blog/the-search-for-speed-in-figma-opensearch/"
source: "Figma"
published: "2024-10-10"
difficulty: "medium"
kind: "Case study"
reading_minutes: 11
tags: ["search","performance","observability","cost-optimization","cloud"]
---

# The search for speed in Figma

A post on [Figma](https://swe.quest/sources/figma.md), published 2024-10-10, 11 min read, Case study. Original: [https://www.figma.com/blog/the-search-for-speed-in-figma-opensearch/](https://www.figma.com/blog/the-search-for-speed-in-figma-opensearch/)

## Summary

Figma's search slowness traced mostly to its own stack, not OpenSearch: OpenSearch's headline 8 ms metric was per-shard time, and only the "took" field in responses reveals overall query latency, which accounted for under 30% of API time. Fixes included reordering and slimming Ruby permission checks, repairing a database connection setup bug that also sped up the rest of Figma, and trimming index size by 50% and then 90% so the data fit in the OS page cache. Load tests with a custom Go benchmark showed AWS sizing guidance suited log workloads, not latency-sensitive search. Cutting shards from 450 to 180 and moving to nodes with less CPU and more RAM paid off, while concurrent segment search hurt. Overall API latency fell about 60%, peak QPS rose over 50%, and cost dropped more than 50%.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Search](https://swe.quest/tags/search.md) (Backend & APIs)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)
- [Observability](https://swe.quest/tags/observability.md) (Reliability & operations)
- [Cost optimization](https://swe.quest/tags/cost-optimization.md) (Reliability & operations)
- [Cloud platforms](https://swe.quest/tags/cloud.md) (Infrastructure)

## Prerequisites

- Elasticsearch/OpenSearch shards and nodes ([easy posts on Search](https://swe.quest/tags/search.md?difficulty=easy))
- latency percentiles ([easy posts on Performance engineering](https://swe.quest/tags/performance.md?difficulty=easy))

## Keywords

OpenSearch, Elasticsearch, AWS OpenSearch Service, Datadog, Zstandard, opensearch-benchmark, Ruby

## Related posts

- [The infrastructure behind AI search in Figma](https://swe.quest/articles/the-infrastructure-behind-ai-search-in-figma-b7fada64ae683a10.md): Figma · 2024-10-15 · Medium · 10 min read · Vector search, Search, Cost optimization, Inference & serving, Scaling
  Figma's AI search embeds frames and published components with a CLIP-based multimodal model, so screenshots, layer selections and text all query one vector space.
- [How Canva achieved 10x faster search and 70% lower costs with ClickHouse](https://swe.quest/articles/how-canva-achieved-10x-faster-search-and-70-lower-costs-with-clickhouse-40e415ef239059a0.md): ClickHouse · 2025-12-01 · Medium · 7 min read · Observability, Analytics & OLAP, Cost optimization, Performance engineering, Databases
  Canva moved tracing and logging (about 3 million spans and 3 million logs per second) onto a self-managed ClickHouse cluster of 5 shards × 3 replicas on Kubernetes.
- [How we built AI search in Figma](https://swe.quest/articles/how-we-built-ai-search-in-figma-a7e536f5730f5136.md): Figma · 2024-10-25 · Easy · 10 min read · Search, Evaluation, Product engineering, RAG & retrieval
  Figma pivoted from an AI design-autocomplete prototype to shipping visual and semantic search after research showed 75% of objects added to the canvas come from other files and designers struggle to find mid-level frames.
- [Observability At Scale — Every Byte Counts](https://swe.quest/articles/observability-at-scale-every-byte-counts-3491ffe2c3088798.md): Wise Engineering · 2026-10-20 · Medium · 14 min read · Observability, Cost optimization, Performance engineering, Kubernetes
  Five observability changes at Wise cut monthly spend by 40%.
- [The Day Our Own Queries DoS’ed Us: Inside Zalando Search](https://swe.quest/articles/the-day-our-own-queries-dos-ed-us-inside-zalando-search-67652f0dd340b67a.md): Zalando Engineering · 2025-12-16 · Medium · 10 min read · Search, Incidents & postmortems, Resilience, Observability, Performance engineering
  A Zalando Elasticsearch cluster serving two large markets was overwhelmed by a self-inflicted denial of service: a bug in an internal maintenance workload made an application send only 20-100 requests per second of faceting queries aggregating on SKU, a unique-per-product, extremely high-cardinality field.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
