Trade Widget
The Trade Widget is a ready-made trading UI hosted by Coinify, embedded into your web page via an iframe. It handles the complete end-user experience — onboarding, KYC, quotes, payment, and trade history — with no trading UI to build on your side.
Basic setup
Add an iframe element to your page pointing to the Trade Widget URL, with your partnerId as a required query parameter:
<!-- Sandbox -->
<iframe
src="https://trade-ui.sandbox.coinify.com?partnerId={your-partner-id}"
width="100%"
height="576px"
allow="camera;fullscreen;accelerometer;gyroscope;magnetometer;payment"
allowfullscreen>
</iframe>
<!-- Production -->
<iframe
src="https://trade-ui.coinify.com?partnerId={your-partner-id}"
width="100%"
height="576px"
allow="camera;fullscreen;accelerometer;gyroscope;magnetometer;payment"
allowfullscreen>
</iframe>The
allowandallowfullscreenattributes are required. They enable camera access for KYC identity verification and Apple Pay support. If you are nesting the widget inside anotheriframe, these attributes must be added to everyiframein the chain.
Widget dimensions
The widget is responsive and adjusts its layout to the available width:
| Layout | Min width | Max width |
|---|---|---|
| Mobile | 320px | 575px |
| Tablet | 576px | 768px |
| Desktop | 769px | / |
The minimum recommended height is 576px. Increasing the height stretches the widget and hides scrollbars on text-heavy pages like Trade Details. There is no maximum width, but a minimum of 320px is required — on the smallest mobile screens, avoid adding horizontal margin or padding around the widget.
Query parameters
Configure the widget's behaviour and appearance by appending query parameters to the URL.
Every query parameter must be URL-encoded, e.g. using
encodeURIComponent()in JavaScript.
Partner configuration
| Parameter | Description |
|---|---|
partnerId | Required. Your Partner ID as assigned by Coinify. |
partnerName | Name displayed in the widget (e.g. next to a partner fee). Defaults to 'Partner'. |
partnerContext | Free-form context passed back to you in webhook payloads. Accepts a string or stringified JSON. |
Look & feel
| Parameter | Description |
|---|---|
primaryColor | Colour of the primary button. Accepts a named value (e.g. blue), hex (e.g. #00ff00), or rgba. |
themeMode | Widget theme — light or dark. Defaults to light. |
Currencies
| Parameter | Description |
|---|---|
cryptoCurrencies | Comma-separated list of cryptocurrencies to offer (e.g. BTC,ETH,XLM). Limits to a subset of Coinify-supported currencies. |
fiatCurrencies | Comma-separated list of fiat currencies to offer. |
defaultCryptoCurrency | The cryptocurrency pre-selected on the quote screen when multiple are available. |
defaultFiatCurrency | The fiat currency pre-selected on the quote screen when multiple are available. |
Trade amounts
| Parameter | Description |
|---|---|
buyAmount | Pre-fills the amount on the Buy quote screen. |
sellAmount | Pre-fills the amount on the Sell quote screen. |
isBuyAmountFixed | Set to true to lock the buyAmount so the end-user cannot change it. |
isSellAmountFixed | Set to true to lock the sellAmount so the end-user cannot change it. |
isBuyAmountWithFees | Set to true so that buyAmount is treated as fees-included — the amount the end-user will spend in total. |
isSellAmountWithFees | Set to true so that sellAmount is treated as fees-included. |
Wallet address
| Parameter | Description |
|---|---|
address | Pre-fills the receiving wallet address (Buy) or refund address (Sell). See How to use address below. |
addressSignature | HMAC-SHA-256 signature for the address value. Required if you have established a shared secret with Coinify. |
walletType | Wallet type — self_hosted (user's own wallet) or vasp (hosted by a third-party exchange). If not provided, the end-user is prompted to select. |
vaspId | Required when walletType is vasp. If provided, the VASP selection screen is skipped. See Supported VASPs →. |
memo | Optional memo or destination tag for cryptocurrencies that support it. |
Navigation & access
| Parameter | Description |
|---|---|
targetPage | Landing page when the widget loads. Values: login, signup, signup-corporate, buy, sell, trade-history. |
refreshToken | Passes an authenticated session into the widget — used for Frictionless Sign-in. Must be URL-encoded. |
noSignup | Controls sign-up availability. true disables sign-up entirely; corporate allows only individual sign-up; individual allows only corporate sign-up; false allows both. |
confirmMessages | When set, the widget waits for external confirmation before proceeding after key trade events. See Sending/Receiving Widget Messages →. |
Payment methods
| Parameter | Description |
|---|---|
transferInMedia | Comma-separated list of accepted inbound payment methods. Available: card, bank, applepay, googlepay, blockchain. |
transferOutMedia | Comma-separated list of accepted outbound payment methods. Available: bank, blockchain. |
Return URL
| Parameter | Description |
|---|---|
returnURL | URL to redirect the end-user to after a successfully completed trade. Must be URL-encoded. Only available on the Customised Landing Page. |
Improve UX by skipping screens
Passing certain parameters removes steps the end-user would otherwise have to complete manually. If you already hold any of this data, pass it through to streamline the flow:
| Parameter(s) | Screen skipped |
|---|---|
transferInMedia | Payment method selection screen |
buyAmount + defaultFiatCurrency + defaultCryptoCurrency | Quote screen |
address | Wallet address entry screen |
walletType | Wallet type selection screen |
vaspId | VASP selection screen (when walletType is vasp) |
Enabling Buy, Sell, or both
By default the widget enables both Buy and Sell with all available payment methods. Use transferInMedia and transferOutMedia to restrict this:
| Use case | Parameters |
|---|---|
| Buy only (card or bank), Sell disabled | transferInMedia=card,bank |
| Buy only (all methods), Sell disabled | transferOutMedia=blockchain |
| Buy via bank transfer only | transferInMedia=bank |
| Sell only (all methods), Buy disabled | transferInMedia=blockchain |
How to use address
addressFor a single cryptocurrency, pass the address directly:
<iframe src="...?cryptoCurrencies=BTC&address=2N7gzbQsDnfAFdwabcFqyw1Q8y1ZUpeqUgD&..." />For multiple cryptocurrencies, use the currency:address format:
<iframe src="...?address=BTC:2N7gzbQsDnfAFdwabcFqyw1Q8y1ZUpeqUgD,ETH:0x44eae1E05F5f294f0f2a054D16605993FCd627a9&..." />The same format applies to addressSignature and memo.
Securing the address with a signature
If you pre-fill wallet addresses, it is strongly recommended to sign them using a shared secret to prevent tampering. Share a UUID-format secret with Coinify via a secure channel to enable this feature — once enabled, trades with unsigned or incorrectly signed addresses will be rejected.
Generate the signature using HMAC-SHA-256:
const crypto = require('crypto');
const address = 'your-crypto-address';
const secret = 'your-shared-secret';
const addressSignature = crypto.createHmac('SHA256', secret).update(address).digest('hex');Then pass both address and addressSignature as query parameters.
addressSignatureis an opt-in feature and requires a shared secret to be established with Coinify first.
Customised Landing Page
Coinify can provision a dedicated landing page URL for your Trade Widget with custom branding — your logo, brand colours, browser tab title, and page URL path. To set this up, contact Coinify through your dedicated communication channel and provide
- Partner Title — browser tab title (e.g.
Crypto Company) - Partner Name — defines the URL path (e.g.
https://trade.coinify.com/YourCompanyName) - Primary Colour — button colour (e.g.
#4231c8) - Light & Dark Colour — gradient background colours behind the widget
- Logo — an
.svgfile of your logo - Website URL — linked behind your logo on the landing page
The returnURL query parameter is exclusively available on the Customised Landing Page, allowing you to redirect users back to your product after a completed trade.
Next steps
- Frictionless Sign-up Flow → — silently onboard your users without a Coinify sign-up screen
- Frictionless Sign-in → — pass an authenticated session into the widget via
refreshToken - Enable Apple Pay → — additional setup steps required for Apple Pay
- Trade Widget SDK → — prefer a JavaScript-based integration over a raw iframe
