JavaScript Library

Integrate athletics scoring tables into your website and calculate points directly in the browser.

What does this library do?

The library adds five functions to your website. With waScore and waMark you convert an athletics performance into World Athletics points or, conversely, find the equivalent performance for a given score. With waCombinedScore and waCombinedMark you calculate the points of each event in a decathlon, heptathlon or pentathlon. And waVersion tells you which tables it uses. Everything runs directly in the user's browser: no backend, no API and no network requests are needed for the calculations.

See price and licence

One-time payment. Instant download. Commercial use allowed.

What's included, and why

Everything in the package is there for a reason: to let you go from download to working scores in a few minutes, whatever kind of project you have.

How it's made

When you calculate scores, "almost right" isn't good enough. A single point can change a ranking. That's why this library went through a long process before I was happy to release it.

  1. From official PDFs to clean data

    World Athletics publishes the scoring tables as PDF documents. The first step was extracting every mark and turning those documents into clean, ordered data, table by table.

  2. Following the official rules

    Marks are rounded and formatted exactly as World Athletics specifies. For example, road events are scored in whole seconds, except the road mile. Many calculators skip these details, and that's where small errors creep in.

  3. From data to formulas

    The first version carried the complete tables inside the library and weighed 1.7 MB. To make it lighter, I worked out the formulas behind every table, including the events that need their own exceptions.

  4. Checked against the original

    I ran the new library and the original one, built from the official data, over every mark of every table, from the 50 metres to the mixed relays. I exported both sets of results and compared them value by value. All of them matched, and only then did I release it.

If an error is ever found, every buyer will receive the corrected version at no extra cost.

David Ballester Ribó competing in the 400 metres hurdles in the Spanish First Division, 2025
Built by an athleteI'm David Ballester Ribó. I competed in the 400 metres hurdles at the Spanish U20 Championships, and I learned JavaScript by building the calculator on this website. I made this library for the athletics community, and when you write to me, I'm the one who answers. Read the full story.

From 1.7 MB to 27 KB

The first version of the library loaded the complete scoring tables and weighed 1.7 MB. By replacing the data with the formulas behind it, the current version does exactly the same job, and also includes combined events, in a fraction of the size.

  • First version100%1.7 MB
  • Current version1.6%27 KB
  • Transferred (gzip)0.4%< 7 KB
About 98.4% smaller than the first version.
27 KB
Full library, with every WA table and the combined events tables
Once
Each gender and event is prepared on first use and kept in memory
No requests
Calculations never need to contact an external server

A smaller file loads faster, especially on mobile devices, and lets you process thousands of results without a single server request.

What can you build with the library?

A few ideas of what clubs, media outlets and federations can do with World Athletics points:

Installation

Integrating the library into your website is simple. Download the ZIP file, choose the version that best suits your project and follow the steps below.

  1. Download the .zip file. It includes both versions of the library, working examples and the list of event identifiers.
  2. Upload the JavaScript file to your website, for example alongside the other JavaScript files in your project.
  3. Add the appropriate integration code to the page where you want to use the scoring tables.
  4. Call waScore(gender, event, performance), waMark(gender, event, points) or the combined events functions with your data.

The .zip file includes both versions of the library. They use the same scoring tables and provide the same functions; the only difference is how they are integrated into your project.

Classic Script

The simplest option for traditional HTML pages and projects where you want to load the library using a <script> tag.

<script src="wa-scoring-tables-2025.js"></script>
<script>
  const points = WAScore.waScore("m", "100m", "10.85");
  console.log(points); // 931
</script>

ES Module

Ideal for modern projects using JavaScript modules or tools such as Vite, Webpack or Next.js. It is also a good choice if you prefer using import.

<script type="module">
  import { waScore } from './wa-scoring-tables-2025.esm.js';

  const points = waScore("m", "100m", "10.85");
  console.log(points); // 931
</script>

API: Available functions

The library includes five functions to check the table version, convert between performances and World Athletics points, and calculate combined events points.

Quick reference for the available functions.
FunctionDescription
waVersion()Returns the version of the scoring tables included in the library.
waScore(gender, event, performance)Converts an athletics performance into World Athletics points.
waMark(gender, event, points)Converts World Athletics points into the equivalent performance.
waCombinedScore(gender, event, mark, manual)Returns the points of one event inside a combined event. The optional fourth parameter applies the official manual timing adjustment.
waCombinedMark(gender, event, points)Returns the mark needed for a score in one event of a combined event.

Parameters are provided as strings: the gender ("m", "w" or "x"), the event identifier (for example, "100m" or "HJ") and the corresponding performance or score.

Event identifiers

Each event uses an identifier so that you can easily reference it from JavaScript. The ZIP file includes the complete list of all 86 events, and combined events use the same identifiers.

100m
100 Metres
400mH
400 Metres Hurdles
HJ
High Jump

Identifiers are case-sensitive: 100m works, 100M does not.

Example: building a ranking

One of the most common use cases is creating a ranking from a list of results. You can automatically calculate each athlete's points and then sort the results from highest to lowest score.

const results = [
  { name: "Marc Vidal",  gender: "m", event: "100m", performance: "10.85" },
  { name: "Laia Ferrer", gender: "w", event: "800m", performance: "2:05.30" },
  // ...the rest of the results
];

const scored = results.map(r => ({
  ...r,
  points: WAScore.waScore(r.gender, r.event, r.performance)
}));

scored.sort((a, b) => b.points - a.points);

All functions are synchronous. You do not need to use await or handle promises: the result is available immediately.

Don't code? I'll help you install it

You don't need to be a developer to use the library. Whether your website runs on WordPress, Wix, Squarespace or was built from scratch, write to me, tell me what you want to show and I'll help you find the best way to add it.

Ask for installation help

Compatible with your project

The library uses standard JavaScript and can be integrated into any project that allows JavaScript to run.

Versions and updates

This library uses the World Athletics 2025 Scoring Tables and the IAAF Scoring Tables for Combined Events, and you can check this at any time with waVersion().

Version
World Athletics Scoring Tables 2025 and IAAF Scoring Tables for Combined Events (2001 edition)
Corrections
If an error is found, every buyer receives the corrected version at no extra cost.
New tables
When World Athletics publishes new tables, I'll release a new version of the library, and previous buyers will receive a discount link.

Frequently asked questions

Does it require an Internet connection to calculate points?

No. The scoring tables are included directly in the JavaScript file you download. Once the library has loaded, calculations do not need to connect to any external server.

Does it work with WordPress, Wix or Squarespace?

Yes. The library uses standard JavaScript and can be used on these platforms as long as your setup allows you to add JavaScript. On WordPress, you can use a Custom HTML block or a suitable code-injection tool. On Wix and Squarespace, you can use their options for adding custom code.

Can I use it in commercial projects?

Yes. The licence allows personal and commercial use, on as many websites and applications as you need.

Can I use it on websites I build for clients?

Yes. The licence covers every website and application you develop for clients, as long as the library is only used as part of the project you deliver.

Can I use the library on multiple pages of my website?

Yes. You can load the library and use its functions on as many pages of your project as you need.

Is this an official World Athletics product?

No. It's an independent project that reproduces the official World Athletics Scoring Tables 2025.

Price and licence

Integrate the World Athletics Scoring Tables into your website and start working with points, rankings and results without an API or backend.

JavaScript Library

€79

One licence for clubs, federations, media outlets and developers.

  • Unlimited websites and applications
  • Results, rankings and statistics of any club
  • Websites you build for clients included
  • Both versions, examples and the list of identifiers
  • Error messages and documentation in English
  • Free corrections and email support
Buy the library

Any questions before buying? Write to me and I'll help you.

A single licence with no limits on where you use it. Clubs, federations, media outlets and developers get exactly the same library and the same rights.

One-time payment. Instant download. Commercial use allowed.