Ask Dave Taylor
  • Facebook
  • Instagram
  • Linkedin
  • Pinterest
  • Twitter
  • YouTube
  • Home
  • YouTube Channel
  • Most Popular
  • Newsletter!
  • Ask Me A Question
  • Meet Dave
  • Home
  • Windows PC Help
  • How Can I Quickly Convert Octal to Hexadecimal?

How Can I Quickly Convert Octal to Hexadecimal?

November 15, 2019 / Dave Taylor / Windows PC Help / No Comments

I’m learning how to program and my homework often includes number base conversion. I guess my teacher likes that kind of thing! Is there any easy way to convert numbers on a PC? Thanks.

  CLICK TO GET DAVE'S FREE NEWSLETTER! 
Guaranteed to Make you Smarter.

Once computers began being built around simple binary switches – on / off – it was perhaps inevitable that the language of computers would embrace base-2, base 2**3 and base 2**4 numbers too. What are they? Binary (base 2), Octal (base 8) and Hexadecimal (base 16). As your teacher has undoubtedly already told you, the more bits you have for each digit, the less digits are required to express large numbers. 100 decimal (base 10) is 1100100 in binary, but only 64 in hex!

What’s great is that there are a lot of ways you can convert numbers between these bases on your Windows PC, even down to the lowly Calculator program included with Windows 8, Windows 10 and, heck, probably the original Windows 3.1 release. The trick is that the Calculator has a variety of different modes, you just have to hunt for them.

So let’s start there since it’s the easiest. Launch the Calculator on your Win10 computer, then click on the three horizontal lines button on the top left and choose “Programmer” from the list of calculator options:

windows calculator - programmer scientific modes

Turns out there are four major modes for the Calculator: Standard, Scientific, Programmer and Date Calculation. Want to know how many seconds you’ve been alive? You can figure that out with the date calculator. But let’s stick to topic, so choose “Programmer“, as shown above. I did a tiny bit of resizing to make it look neater and… here it is!

win10 calculator - programmer mode - base conversion

Now you can use the number pad and do binary machine-esque calculations like applying an XOR or NOT, but for base calculations it’s way easier: Just click on the base you want to enter then either using the number pad in the app or your own keyboard enter the base number. In this case, I want to convert 7654 Octal to Hexadecimal (“hex” for short).

I’ve done that above: You can see that the answer is FAC or, more accurately 0xFAC using a standard base notation. It’s also convert the octal number to binary – 111110101100 – and decimal – 4012 – instantly too. Want to convert the other way? A click on “DEC” for decimal and we can find out what 2019 is in the various bases too:

windows calculator - programmer mode - octal hex binary conversion

So we’re really in year 3743 if, uh, we were living in a base-8 world.

But it doesn’t stop there. You can do conversions directly in Cortana search too. I kid you not:

programmer base hex binary conversion - cortana search

In this case, you need to know the full number base prefix notation: a zero followed by a letter to denote the non-decimal base. So ‘o’ for octal, ‘b’ for binary and ‘x’ for hex. As shown above, that’s the output format too, so FAC becomes 0xFAC.

You can enter exactly the same query to Bing and it’ll solve it without having to go to a Web site too:

windows bing search conversion hex binary octal

Google can do this nifty little trick too.

If you had access to a Linux command line (and lots of Windows users add the Linux subsystem too) you can also do conversion directly on the command line if you really want to go old school. This involves utilizing a crufty old program called bc, for ‘binary calculator’. Its inputs need to be specified in the input stream, so echo is typically used. Then ibase specifies the input base and obase specifies the output base. Like this:

$ echo 'ibase=8;7654' | bc
4012
$ echo 'obase=16;7654' | bc 
1DE6
$ echo 'obase=16;ibase=8;7654' | bc
FAC

The first example converts 7654 octal to decimal (4012), the second converts 7654 decimal (no input base specified) to hexadecimal (1DE6) and the third converts octal to hex. Pretty cool, actually. Just beware that you have to specify the obase before the ibase for the more obscure conversions to work.

That’s it. Lots of different ways to quickly and easily convert between common numeric bases!

Pro Tip: I’ve been writing about Windows from both a user and programmer perspective for years. Check out my Windows help library for lots of interesting tutorials.

About the Author: Dave Taylor has been involved with the online world since the early days of the Internet. Author of over 20 technical books, he runs the popular AskDaveTaylor.com tech help site. You can also find his gadget reviews on YouTube and chat with him on Twitter as @DaveTaylor.

Let’s Stay In Touch!

Never miss a single article, review or tutorial here on AskDaveTaylor, sign up for my fun weekly newsletter!
Name: 
Your email address:*
Please enter all required fields
Correct invalid entries
No spam, ever. Promise. Powered by FeedBlitz
Please choose a color:
Starbucks coffee cup I do have a lot to say, and questions of my own for that matter, but first I'd like to say thank you, Dave, for all your helpful information by buying you a cup of coffee!
base conversion, bc linux, calculator programmer, convert base, convert octal hex, cortana tricks, financial calculator, hexadecimal, octal, windows calculator

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Search

Recent Posts

  • Add Google News to your Android Phone Home Screen
  • Can’t Move My Recycle Bin to The Corner of my Desktop?
  • Fix a B&N Nook Android Tablet with the Wrong Time
  • How to Make App Icons Bigger on a Samsung Galaxy Phone
  • How to Fix the Location of an iPhone Photograph

On Our YouTube Channel

Never in the dark with the iRonsnow CONDOR 1 Emergency Crank Radio

The Easy to Use ClonerAlliance UHD Pro 4K Video Recorder

Categories

  • AdSense, AdWords, and PPC Help (106)
  • AI and ChatGPT Help (57)
  • Alexa, Kindle, and Nook Help (106)
  • Amazon, eBay, and Online Shopping Help (172)
  • Android Help (298)
  • Apple iPad Help (156)
  • Apple Watch & Smartwatch Help (63)
  • Articles, Tutorials, and Reviews (361)
  • Auto Tech Help (26)
  • Business Advice (202)
  • Chromebook & ChromeOS Help (74)
  • Computer & Internet Basics (834)
  • d) None of the Above (170)
  • Facebook Help (397)
  • Google, Chrome & Gmail Help (215)
  • HTML & Web Page Design (249)
  • Instagram, Bluesky & Threads Help (65)
  • iPhone & iOS Help (693)
  • iPod & MP3 Player Help (173)
  • LinkedIn Help (95)
  • Linux Help (182)
  • Linux Shell Script Programming (93)
  • Mac & MacOS Help (980)
  • Most Popular (16)
  • Outlook & Office 365 Help (49)
  • PayPal Help (69)
  • Pinterest Help (58)
  • Reddit Help (23)
  • SEO & Marketing (83)
  • Spam, Scams & Security (123)
  • Trade Show News & Updates (23)
  • Video Game Tips (66)
  • Web Site Traffic Tips (62)
  • Windows PC Help (1,061)
  • Wordpress Help (207)
  • Writing and Publishing (72)
  • X/Twitter Help (230)
  • YouTube Help (52)
  • YouTube Video Reviews (159)
  • Zoom, Skype & Video Chat Help (75)

Archives

Social Connections:

Ask Dave Taylor


Follow Me on Pinterest
Follow me on Twitter
Follow me on LinkedIn
Follow me on Instagram


AskDaveTaylor on Facebook



microsoft insider mvp


This web site is for the purpose of disseminating information for educational purposes, free of charge, for the benefit of all visitors. We take great care to provide quality information. However, we do not guarantee, and accept no legal liability whatsoever arising from or connected to, the accuracy, reliability, currency or completeness of any material contained on this site or on any linked site. Further, please note that by submitting a question or comment you're agreeing to our terms of service, which are: you relinquish any subsequent rights of ownership to your material by submitting it on this site. Our lawyer says "Thanks for your cooperation."
© 2025 by Dave Taylor. "Ask Dave Taylor®" is a registered trademark of Intuitive Stories, LLC.
FTC Notice: If you buy products through links on this site we may receive a modest affiliate commission. This won’t affect the price you pay.
Privacy Policy - Terms and Conditions - Accessibility Policy - Humix Video Content
  • Home
  • YouTube Channel
  • Most Popular
  • Newsletter!
  • Ask Me A Question
  • Meet Dave