Omni Calculator logo

Rational or Irrational Calculator

Enter the number! 

Did we solve your problem today?

Check out 78 similar arithmetic calculators ➗

GCF

Average

Modulo

Build your calculator with Builder

Add as preferred on Google

Our rational or irrational calculator instantly tells you whether a number is rational or irrational; no more staring at endless decimals trying to figure it out! Just type in a number or expression, like √2 (type sqrt(2)), π/6 (pi/6), or even a simple fraction, and Omni’s rational number calculator gives you the answer right away without wrestling with long calculations yourself. Wondering about this classic brain teaser: is pi an irrational or rational number? Spoiler: π\pi is irrational.

But this isn’t just a rational and irrational numbers calculator. Our tool also checks if your number is real or complex, so it covers a bit of everything.

Stick around, and we’ll:

  • Break down rational vs. irrational numbers;
  • Discuss rational numbers examples;
  • Explore what numbers are not rational; and
  • Answer tricky cases like ”is 0 rational or irrational?”

What are rational and irrational numbers?

A rational number is basically any number you can write as a fraction ab\frac{a}{b}, where both aa and bb are integers, and bb isn’t zero. It sounds straightforward, and it pretty much covers most of the numbers you deal with every day. Read in detail how to turn a fraction into a decimal.

Irrational numbers don’t fit into that neat fraction form. Their decimal expansion runs forever, with no repeating pattern in sight.

That’s the essence of rational vs. irrational numbers: can you write it as a simple fraction or not?

Numbers system. Complex numbers (C) include the real (R), which include the rational (Q), which include the integers (Z), which include the natural numbers (N).

Let’s see where rational and irrational numbers actually sit in the bigger picture. Take a look at the diagram above: in the middle, you’ve got natural numbers (N\natnums) and integers (Z\Z). Then, when you zoom out, you reach decimals (𝔻𝔻). Every decimal (terminating and repeating) in this set is rational, but not every rational number is a decimal in this narrow sense. Zoom out again, and you land on rational numbers (Q). Go even further, and you get to the real numbers (R\reals), which include the irrationals too. So, what numbers aren’t rational? Anything inside R\reals but outside that Q circle.

And finally, the biggest group is complex numbers (C\cnums). They cover all the others, plus numbers with an imaginary part, such as ii or 1+i31 + i\sqrt{3}. Learn more about these number types with our complex number calculator.

💡 If you’re curious about how sets overlap and interact more generally, our Venn diagram calculator is a great place to explore that.

Examples of rational numbers (and what numbers are not rational)

Let’s look at some solid rational numbers examples to make this stick. Whole numbers like 44, fractions such as 34\frac{3}{4}, terminating decimals such as 0.250.25, and repeating decimals like 0.333...0.333... are all rational numbers; basically, any number you can write as a fraction ab\frac{a}{b}. Once you have it, you can always try reducing fractions to their simplest form.

On the other hand, you’ve probably heard of π\pi, 2\sqrt{2}, and ee (Euler’s number); those are the classic examples of irrational numbers. Their decimal expansions keep going and going, with digits that never settle into a pattern, no matter how long you calculate.

Check the table below to see a few options compared side by side:

Rational

Irrational

12\frac{1}{2}

2\sqrt{2}

0.750.75

π\pi

711-\frac{7}{11}

ee

4=2\sqrt 4 = 2

φ\varphi (golden ratio)

1.333...1.333...

sin(1)\sin(1)

Still not sure what is a rational or irrational number in your specific case?

Omni’s rational or irrational calculator checks if your number can be rewritten as a fraction of two integers ab\frac{a}{b}; either directly, through a known irrational source, or by testing whether the decimal value matches a simple fraction closely enough. If a clean ab\frac{a}{b} form exists, the number is rational; if not, it’s irrational.

Is 0 rational or irrational number and other tricky examples

Here’s a bit of a trickier question: is 0 rational or irrational? Zero is actually rational, because you can just write it as 01\frac{0}{1} which totally matches the whole ab\frac{a}{b} rule.

Once you pay attention, these rational vs. irrational numbers show up in places you’d never expect. Here are some everyday examples of rational numbers to bring it all to life (or test your own with our rational or irrational calculator).

Situation

Rational number

A 15-second Instagram Reel split into 33 equal clips

5 seconds (153\frac{15}{3})

A pizza delivery split between 66 roommates

16\frac{1}{6} each

Your phone battery at 62%62\%

62100\frac{62}{100}

A 90-minute Netflix episode watched at 1.5x speed

60 minutes (901.5\frac{90}{1.5})

Irrational numbers pop up in quieter, less obvious places:

  • TikTok’s “For You” algorithm — the ranking systems behind content recommendations rely on complex statistical models, some of which use irrational constants like ee;
  • Wi-Fi and Bluetooth signals — their frequencies are based on π\pi because radio waves behave like circles or sine waves;
  • Geometry — diagonal of a square with sides of one unit is 2\sqrt{2}, which was actually the first irrational number ever found; and
  • Patterns in nature — spirals in shells or sunflower seeds often follow the golden ratio φ\varphi, about 1.618.

How to use rational or irrational calculator

Using our rational or irrational calculator is pretty intuitive:

  1. Type in your number. It can be a whole number, a fraction, a decimal, or something like 2\sqrt{2} or sin(π6)\sin(\frac{\pi}{6}). For example, type sqrt(2) to input the square root of 2 and use pi instead of the symbol π\pi.
  2. Let the rational number calculator handle the rest. It quickly determines whether your number fits the form ab\frac{a}{b}, where aa and bb are integers and b0b \not = 0.
  3. Check your result. Omni’s rational and irrational numbers calculator will tell you if your number is rational or irrational, and it also shows you its domain (real or complex) and whether it’s positive or negative.
  4. Repeat. There’s no limit to how many you can check.

FAQs

What are rational and irrational numbers?

A rational number can be written as a fraction a/b, while an irrational number cannot. Rational numbers either terminate (like 0.25) or repeat (like 0.333...), while irrational numbers, like π or √2, go on forever without settling into a pattern, no matter how far you calculate.

How can I tell if a number is irrational or rational?

Use the following process to check if a number is irrational or rational:

  1. Check if it's already written as a fraction, a/b. If so, it's rational.
  2. Convert it to a decimal.
  3. If the decimal terminates or repeats, it's rational.
  4. If it goes on forever with no pattern, it's irrational.

Is pi an irrational or rational number?

Pi is irrational. Its decimal expansion never ends and never repeats, no matter how many digits you calculate, even 22/7 is only a close approximation, not its true value.

Is 1/3 rational or irrational?

1/3 is rational. It’s already written as a fraction of two integers, which is exactly what makes a number rational, even though its decimal form (0.333...) repeats forever, the fraction itself is what counts.

Is 5 rational or irrational?

5 is rational. Every integer is rational, since it can be written as a fraction with 1 as the denominator: in this case, 5/1.