tode

tode compared with other tools

Amplitude in a Figma plugin, compared with tode

Amplitude runs in the plugin iframe with identity storage off and autocapture disabled. What its funnels and cohorts are worth to a plugin, and when a fixed dashboard is enough.

, by Ilia

Amplitude is a product analytics suite built for teams that live in charts: funnels, cohorts, retention curves, experiments. Its browser SDK runs inside a plugin iframe once you turn off the two things it does by default, storing an identity and capturing page activity. After that it is a question of size. Amplitude gives you far more than a plugin usually needs, and you pay for that in setup and in the time it takes to find your five numbers.

Running Amplitude in a plugin

The Browser SDK (@amplitude/analytics-browser) keeps the user and device id in a cookie by default. The plugin UI has a null origin and no cookies, so set identityStorage to none. Autocapture is on by default since version 2.10 and records page views, sessions, form interactions and file downloads. None of that describes a plugin, so turn it off and send your own events.

// ui.ts (the iframe)
import * as amplitude from '@amplitude/analytics-browser';

amplitude.init('YOUR_API_KEY', undefined, {
  identityStorage: 'none',
  autocapture: false,
});

// code.ts sends figma.currentUser.id to the UI once, after showUI
window.onmessage = (e) => {
  const msg = e.data.pluginMessage;
  if (msg?.type === 'identity' && msg.userId) amplitude.setUserId(msg.userId);
};

amplitude.track('fonts_replaced', { count: 12 });
"networkAccess": { "allowedDomains": ["https://api2.amplitude.com"] }

With storage off, the SDK makes a new device id on every open. Amplitude's docs say its identity resolution ties those device ids together once a user id arrives, so set the user id before the first track call. Events sent before it belong to an anonymous device that will never come back. If your project is in the EU data center, the host in the manifest is api.eu.amplitude.com and you set serverZone in the options.

Session length is Amplitude's own: events close together share a session id, and the session ends after a period with no events. For a plugin that sends an event every few seconds this is close to the time it was open. For one where the user reads a result for two minutes and closes the window, the session ends at the last event, not at the close.

Side by side

Amplitudetode
Works in the null-origin iframeYes, with identity storage offYes
User identityYou pass the Figma user id to setUserIdRead from figma.currentUser at init
Session lengthFrom the gap between eventsTime the UI connection is open
Retention and stickinessYes, configurable chartsYes, fixed definitions
Funnels, cohorts, experimentsYesNo
Event propertiesAny JSONOne numeric metric per event
Figma editor and modeSend them as propertiesAttached to every event
Data regionUS or EUOne region
Event typesLimited per project, the limit is high2 on Free, 20 on Starter, unlimited above
Price modelFree plan, then by tracked users or eventsFree for 1 plugin, then $12 to $99 a month for all your plugins
SetupSDK, two options off, identity message from the controllerinit in the controller, an adapter in the UI

Pick Amplitude if

Your plugin is the front door of a larger product and the company already runs Amplitude. Then plugin events sit next to web and app events, and a funnel can start in Figma and end at a checkout page. Or you have an analyst who will build cohorts and ask questions I have not thought of. Amplitude is very good at that, and a fixed dashboard is not.

Pick tode if

The plugin is the product and you are the whole team. You want to open one page and see active users, who came back, which features they used and how long they stayed, without building a chart first. You have more than one plugin and want one bill. Or you would rather the tool could not collect free-form properties at all, because then you never have to check whether a layer name slipped into one.

The same naming rules apply to both. They are in how to track usage, and the overview of all the options puts Amplitude next to Mixpanel, PostHog and the rest.