Bazi Chart Calculator
0 credits

How this bazi calculator works

Bazi Chart Calculator is a small independent site that turns a birth date, time and place into a bazi chart, also called a four pillars chart. This page explains exactly how the chart is worked out, so you can compare it with any other bazi calculator and see where a difference comes from. The bazi calculator itself is on the front page.

What the calculator does

You enter a birth date, a birth time if you know it, a birth city and a gender. The page then works out the four pillars (year, month, day and hour), the day master, the hidden stems inside each branch, the ten gods, the balance of the five elements and eight ten-year luck pillars. All of this happens in your browser. Your birth details are not sent to a server to make the chart.

The calendar behind the chart

The stems, branches and solar terms come from tyme4ts, an open-source calendar library published under the MIT licence. On top of it, this site adds the handling of time zones and true solar time described below.

A bazi chart does not follow the Western calendar or the lunar new year. It follows the twenty-four solar terms, which mark the sun's position:

Time zones and solar terms

A solar term happens at one moment for the whole planet. The calculator converts your birth to that same frame before it decides the year and month pillars, using the time-zone rules for your birth city on your birth date, including daylight saving time where it applied. A birth in New York a few hours after a solar term therefore lands in the new month, just as it should.

True solar time

Clock time is shared across a whole time zone, but the sun is not. True solar time is the time shown by the sun at the exact longitude of the birthplace. The calculator finds it in two steps: four minutes for every degree of longitude away from the centre of the time zone, plus the equation of time, a seasonal correction of up to about sixteen minutes. Daylight saving time drops out along the way.

When you pick a birth city, true solar time is switched on and it decides the day and hour pillars. You can switch it off to use the clock time exactly as you typed it. Under every chart there is a line that shows the clock time, the time actually used and the size of the correction.

How the five elements are counted

Each of the eight characters belongs to one element: the four stems directly, the four branches by their main element. The percentages on the chart are a simple count of those eight characters. If the birth time is unknown there is no hour pillar and six characters are counted. Other calculators may also weigh the hidden stems or the season, which gives different percentages from the same chart.

Compatibility

When a friend sends you an invitation link, the calculator compares your two charts with a fixed set of traditional rules: how the two day-master elements relate, the five stem combinations, harmonies and clashes between the day branches and the year branches, and whether one chart is strong in an element the other lacks. The same two charts always get the same score. An invitation link stores a display name and the four pillars of the person who made it. It does not store the birth date or birthplace.

The video

The calculator can play a fifteen-second vertical video of a chart. It is drawn in your browser from the chart you just made; no AI video model is involved. The free preview carries a watermark. A paid version without the watermark, together with a full written reading of the chart, is coming soon.

What this site does not do

Bazi is a tradition, and the descriptions here report what that tradition associates with a chart. They are offered for entertainment and cultural interest. The site does not predict events, and it says nothing about money, health or length of life. It is not a consultation with a practitioner and it is not advice of any kind.

Sources and credits

Contact

Questions, a chart you think is wrong, or a problem with a purchase: see the contact page.