We all want our car to go longer on a single tank of gas. While all vehicles come with a mileage or mpg ranking, mileage can actually vary depending on where you live, driving style, vehicle condition, and a host of other factors.

Knowing the actual mileage your vehicle gets is useful information to have and is very easy to calculate. It can help set a baseline as you strive to improve your mpg and will come in handy for trip planning and budgeting for your next long road trip.

Finding the perfect octane rated fuel for your vehicle can help improve mpg as well as make the car run a bit smoother. The octane rating is the measure of a fuel’s ability to prevent or resist “knocking” during the combustion phase. Knocking is caused by fuel igniting prematurely, throwing off the combustion rhythm of your engine. High-octane rated gasoline requires more pressure to ignite and in some vehicles this helps the engine run more smoothly.

Let’s have a quick rundown on how to check your fuel economy and find the best octane rating for your particular vehicle.

### Part 1 of 2: Calculate your miles per gallon

Calculating your miles per gallon is actually a pretty simple operation. You will just need a few items to get ready.

Materials Needed

• Full tank of gas
• Calculator
• Paper
• Pen

Step 1: Fill your vehicle up with gas. The vehicle should be completely full in order to measure the rate of gas use.

Step 2: Reset your trip odometer. This can usually be done by pushing the button sticking out from the instrument panel.

Hold the button down until the odometer resets. If you are not sure how to do it, consult your owner’s manual. If your vehicle doesn’t have a trip odometer or it is not functioning, write down the vehicle mileage in a notebook.

• Note: If your vehicle doesn’t have a trip odometer or it is not functioning, write down the vehicle mileage in a notebook.

Step 3: Drive your vehicle as you normally would around town. Stick to your regular routine as much as possible.

When the tank gets down to half full, move to the next step.

Step 4: Go back to the gas station and fill the car up with gas. The vehicle should be completely full.

• Reminder: If you also want to determine the best octane for your vehicle, fill up with the next highest octane rated gasoline.

Step 5: Record the amount of gas used. Record the mileage on the trip odometer or calculate the elapsed mileage since the last fill-up.

Do this by subtracting the original mileage from the newly recorded mileage. You now have all of the data needed to calculate your mileage numbers.

Step 6: Break out the calculator. Divide the miles you travelled on the half tank of gas by the amount of gas (in gallons) that it took to refill the tank.

For example, if you drove 405 miles and it took 17 gallons to fill your vehicle, your mpg is roughly 23 miles per gallon: 405 ÷ 17 = 23.82 mpg.

• Note: Mpg will vary depending on the driving style of the person behind the wheel as well as the type of driving being done. Highway driving will always result in a higher mpg as there are fewer stops and starts that tend to eat up gasoline.

### Part 2 of 2: Determining optimal octane rating

At most service stations, gas is sold in a three different octane levels. Common ratings are regular gasoline at 87 octane, mid-grade at 89 octane, and premium at 91 to 93 octane rating. The octane rating is usually displayed in large black numbers on a yellow background on gasoline pumps.

The correct octane rated fuel for your vehicle will improve mpg and make the car run smoother. The octane rating is the measure of a fuel’s ability to resist “knocking” during the combustion phase. Finding the proper octane-rated gasoline for your vehicle is pretty simple.

Step 1: Refill your vehicle with higher octane. Once the tank has gotten to half full, refill the vehicle with the next highest octane rated gasoline.

Reset the trip odometer again or jot down the vehicle mileage if the trip odometer does not work.

Step 2: Drive the vehicle as usual. Drive your car in the usual way until the tank gets down to half full again.

Step 3: Recalculate the mpg. Do this with the new octane gasoline by writing down the amount of gas required to refill the tank (in gallons) and the mileage used.

Divide the miles you travelled on the half tank of gas by the amount of gas (in gallons) that it took to refill the tank. Compare the new mpg with the lower octane rated fuel mpg to determine which one works best in your vehicle.

Step 4: Determine the percentage increase. You can determine the percentage increase in mpg by dividing the increase in gas mileage by the mpg of the lower octane rating.

For example, if you calculated 26 mpg at the higher octane rated gasoline versus the 23 you achieved at the lower octane, the difference is 3 mpg. Divide 3 by 23, which results in .13 or a 13 percent increase in mpg between the two fuels.

Experts recommend switching to the higher octane fuel if the increase in mpg is over 5 percent. You can repeat this process using premium fuel to determine if it increases your mpg even higher.

You have now calculated the true mpg for your vehicle and determined what octane rated fuel is best for your car, which is a helpful way to reduce the strain on your wallet and make the most out of your car. If you notice that your car’s mileage is getting worse, have one of YourMechanic’s certified professionals perform an inspection.

This article originally appeared on YourMechanic.com as How to Figure Out Which Type of Fuel Gets the Best Mileage and was authored by Mark Vallet.