Skip to content
calcbloc
EMBED / 13 COUNTRIES / 94 CALCULATORS / FREE

Calculator widget

Put a CalcBloc calculator on your own site. Pick a country and a calculator, copy the code, and paste it into any page. Rates stay current because the calculator runs on calcbloc.com.

Colour scheme

Paste it where the calculator should appear. The “Powered by CalcBloc” line links to the UK Take-Home Pay Calculator page; please keep it visible.

Preview

How it works

Two lines of code

  • The <div class="calcbloc-widget"> marks where the calculator goes; widget.js (a few kilobytes, no dependencies, loaded asynchronously) turns it into the calculator.
  • The calculator runs in a sandboxed iframe, so it cannot change your page's styles or scripts, and yours cannot break it.
  • The frame grows and shrinks with its content, so there is no inner scrollbar, and it fits phone screens.
  • Several widgets can share one page; include the script once.
Reference

Options

data-country
The country, as in the calcbloc.com address (uk, us, australia, new-zealand…) or its two-letter code (gb, au, nz…).
data-calculator
The calculator name shown in the code above, or the last part of the calculator's address.
data-theme
Optional: dark for a dark colour scheme. Light is the default.
data-height
Optional: starting height in pixels before the calculator reports its own (default 640).
Free to use

Terms in short

The widget is free for any website. Keep the “Powered by CalcBloc” link visible: it tells your readers where the figures come from and links to the full calculator with its sources. Results are estimates, as on calcbloc.com; see the disclaimer and privacy policy. Questions: [email protected].