---
title: "Discussion on \"Why 6% isn't 6%: APY vs. nominal rate in JavaScript (and the double-compounding bug)\" | Hashnode"
description: "Discussion on \"Why 6% isn't 6%: APY vs. nominal rate in JavaScript (and the double-compounding bug)\". I build small finance calculators that run entirely in the browser. The sneakiest bug in this kind of code isn't floating point. It's feeding the wrong kind of rate into the formula.\nHere's the short"
url: "https://hashnode.com/posts/why-6-isn-t-6-apy-vs-nominal-rate-in-javascript-and-the-double-compounding-bug/6adabee3cc1620c2c202ea8c"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Why 6% isn't 6%: APY vs. nominal rate in JavaScript (and the double-compounding bug)](https://nomadwozo.hashnode.dev/why-6-isn-t-6-apy-vs-nominal-rate-in-javascript-and-the-double-compounding-bug?utm_source=hashnode&utm_medium=feed)

I build small finance calculators that run entirely in the browser. The sneakiest bug in this kind of code isn't floating point. It's feeding the wrong kind of rate into the formula. Here's the short

Oct 23 · 4 min read · nomadwozo.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#webdev](https://hashnode.com/tag/webdev)
-   [#math](https://hashnode.com/tag/math)
-   [#tutorial](https://hashnode.com/tag/tutorial)

## Written by

[Nomad Wozo](https://hashnode.com/@wozo)

@wozo

  
[View profile](https://hashnode.com/@wozo)

Indie maker &amp; digital nomad. I travel, and build small, useful web tools along the way: timers, time zone converters, calculators and more. No sign-ups, just tools that work.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
