# Day boundary: what changes between midnight and the 23:00 Zi hour

Compare the midnight and 23:00 Zi day-boundary conventions on one 23:40 birth record, identify the pillar that actually moves, and see why the late-Zi hour stem must be read off the returned chart rather than assumed to change.

Updated: 2026-10-31 · Wenbu AI-assisted editorial

The two conventions diverge only for births between 23:00 and 23:59. Under the midnight boundary that hour still belongs to the same day, so the day pillar stays put. Under the 23:00 Zi boundary it belongs to the next day, so the day pillar advances by one. Wenbu documents that under the default midnight rule the late-Zi hour stem already follows the library's next-day convention; the cited text does not say how the hour stem is derived after switching to the 23:00 boundary, so compare the two returned hour stems instead of assuming it moves with the day pillar. Year and month pillars are compared with solar terms at the absolute instant and serve as a self-check.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

- The conventions differ only for 23:00–23:59; outside that window the pillars match.

- Switching advances the day pillar; do not assume the hour stem follows—copy both returned hour stems and compare them.

- Year and month pillars are compared with solar terms at the absolute instant and should not move, which makes them a useful self-check.

- Store the boundary setting with the birth record so another reader can reproduce the chart.

## A decision flow for switching the day boundary on one record

1. **Fix the inputs** — Write down the Gregorian date, clock time and time zone, and confirm true-solar-time correction is off, so the boundary rule is the only variable.

2. **Check the window** — Outside 23:00–23:59 both conventions give the same pillars and the comparison is pointless; inside the window, continue.

3. **Switch one setting** — Chart once with the default 00:00 boundary (sect=2), then once with the 23:00 Zi boundary (sect=1), leaving all other inputs untouched.

4. **Compare pillars** — First see whether the day pillar advanced by one; then copy both returned hour stems side by side instead of assuming they follow the day pillar; finally confirm the year and month pillars held.

5. **Save the record** — Store both results with the settings and the birth record, noting that under the default rule the late-Zi hour stem follows the library's next-day convention.

The flow starts from the birth record, checks whether the time falls in 23:00–23:59, then changes only the boundary setting, compares pillar by pillar, and saves the settings with the result.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## What each convention actually claims

A day-boundary rule answers one narrow question: at which moment does a new day begin? The midnight convention starts the day at 00:00, so 23:00 to 23:59 still belongs to the current day and is traditionally called the late Zi hour. The 23:00 Zi convention starts the day when the Zi hour begins, so that same hour is assigned to the following day. Both accept that the Zi hour straddles midnight; they disagree only about which day owns the straddle.

Wenbu states the setting plainly: the default is a 00:00 boundary (sect=2), with a 23:00 Zi boundary (sect=1) available as an option. That makes it a switchable, recordable parameter rather than a vague tradition. Before reading any chart, confirm this setting; with different settings, identical inputs can produce different pillars.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## Why the day pillar moves and the hour stem needs checking

The day pillar follows the day count, so shifting the boundary moves the whole 23:00 block by one day. Wenbu documents that under the default midnight rule the late-Zi hour stem already uses the library's next-day convention, but that statement covers the default only; the cited text does not describe how the hour stem is derived once you switch to the 23:00 boundary. In this record the day pillar is the pillar the setting demonstrably moves, while the hour stem is an item to check against the returned charts rather than infer from the day pillar.

The hour branch comes from the clock time, and 23:00–23:59 is the Zi branch under either convention, so the branch stays. The year and month pillars are compared against solar-term moments using the absolute birth instant, so the boundary point does not touch them. That gives you a self-check: if the year or month pillar also changes after switching, something other than the day boundary moved, perhaps the time zone or true-solar-time correction, and you should step back and re-check the inputs.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## The exception inside the default rule

One line in Wenbu's documentation is easy to skim past: under the default rule, the late-Zi hour stem still uses the library's next-day convention. In midnight mode, then, the day pillar for a 23:00 birth remains the current day, while the hour stem is taken from the next day's stem. This is a documented convention of the library, not a typo, and knowing it prevents a mismatch between day and hour from being mistaken for a calculation error.

It also explains why it is inaccurate to say the midnight convention simply treats everything as the current day. In the late Zi hour, the day pillar and the hour stem use different references, which is an implementation detail. When comparing calculators, ask how each handles the late-Zi hour stem before arguing about which is right; that question locates the difference faster.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [lunar-typescript · official source](https://raw.githubusercontent.com/6tail/lunar-typescript/master/README.md)

## Running the comparison on one record

Take a birth record whose time falls between 23:00 and 23:59. Fix the date, time zone and every other setting, change only the day-boundary rule, and write the two results side by side. Compare the day pillar first, then copy out both hour stems and check them against each other, and finally confirm the year and month pillars are unchanged. If the recorded time is outside that window, both conventions agree and the comparison teaches nothing; use a different record.

The lunar-typescript documentation shows the same stem-branch output format, for example a day labelled Gui You with a Zi hour, which is useful for checking field order. It documents how the tool prints stems and branches; it does not settle which day-boundary tradition is correct. Both have users, so the choice belongs in your written record.

[lunar-typescript · official source](https://raw.githubusercontent.com/6tail/lunar-typescript/master/README.md) · [Wenbu · calculation conventions](https://wenbu.app/methodology/)

## Two day-boundary conventions on the same 23:40 record

| Aspect | 00:00 boundary (default) | 23:00 Zi boundary |
| --- | --- | --- |
| 23:00–23:59 belongs to | The current day, the late Zi hour | The next day, start of the Zi hour |
| Day pillar | Current day's pillar | Next day's pillar, one step on |
| Hour branch | Zi | Zi |
| Hour stem | Taken from the library's next-day convention | Not specified in the cited text; read the returned chart |
| Year and month pillars | Compared with solar terms at the absolute instant | Compared the same way |
| Other times of day | Both conventions agree | Both conventions agree |

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## Hypothetical case: one record born at 23:40

This is a teaching record, not a real person, and it makes no interpretive claim. Suppose someone was born at 23:40 in a UTC+08:00 location with true-solar-time correction off. We only track which characters move when the boundary setting changes.

1. Step one, fix the inputs: Gregorian date, 23:40, UTC+08:00, solar correction off. The day-boundary rule is now the only variable.

2. Step two, chart with the default 00:00 boundary. 23:40 is the late Zi hour, so the day pillar is the current day and the hour branch is Zi; per Wenbu's documentation, the hour stem uses the library's next-day convention.

3. Step three, chart again with the 23:00 Zi boundary. The same instant now belongs to the next day, so the day pillar advances one step and the hour branch stays Zi.

4. Step four, compare side by side: the day pillar differs; the default hour stem follows the next-day reference, and the cited text does not state the rule after switching, so copy both returned hour stems verbatim and compare them without presupposing the outcome. If the year or month pillar also changed, another setting moved too.

5. Step five, write the conclusion: the cause is the boundary point, not the time zone or solar correction.

On the same 23:40 record, switching the boundary rule advances the day pillar by one; whether the hour stem changes must be read from the two returned charts, not presented as a second guaranteed change. This describes a calculation difference only, with no claim about the person.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## FAQ

### If my birth time is not in the 23:00 hour, does the boundary rule matter?

Not for this setting. The two conventions diverge only between 23:00 and 23:59; at other times they produce the same day and hour pillars. If your record falls outside that window, spend the effort on time-zone accuracy and the precision of the recorded time instead.

[Wenbu · calculation conventions](https://wenbu.app/methodology/)

### Why does the default midnight rule still use the next day for the late-Zi hour stem?

It is the convention of the library Wenbu uses: the day pillar stays on the current day, but the late-Zi hour stem follows the next-day convention. This is an implementation detail, not a third tradition. Knowing it keeps a day-versus-hour mismatch from being read as a charting error.

[Wenbu · calculation conventions](https://wenbu.app/methodology/)

### After switching to the 23:00 boundary, does the hour stem move with the day pillar?

The cited Wenbu text documents the late-Zi hour stem only for the default midnight rule and does not state how it is derived after switching. So do not infer it from the day pillar: chart both settings, copy the two hour stems side by side, and compare. If the result surprises you, first check whether another setting changed.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

### What if the year or month pillar also changes after I switch?

The boundary rule affects only the day and hour pillars; year and month pillars are compared with solar-term moments at the absolute instant. If they move too, you probably changed the time zone, clock time or solar correction as well. Step back and keep the boundary rule as the only variable.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

### Which day-boundary tradition is the correct one?

It is a matter of convention, not correctness. Both have users, and the switch exists so the setting is visible. What matters is recording which one you used so another reader can reproduce the chart; treating one convention as the only standard defeats the comparison.

[Wenbu · calculation conventions](https://wenbu.app/methodology/) · [lunar-typescript · official source](https://raw.githubusercontent.com/6tail/lunar-typescript/master/README.md)

## Glossary

- **Day boundary**: The moment at which a new day starts for pillar calculation: 00:00 under the midnight convention, 23:00 under the Zi convention. [Wenbu · calculation conventions](https://wenbu.app/methodology/)

- **Late Zi hour**: The 23:00–23:59 portion of the Zi hour. It belongs to the current day under the midnight rule and to the next day under the Zi rule. [Wenbu · calculation conventions](https://wenbu.app/methodology/)

- **sect parameter**: The setting Wenbu documents for choosing the boundary rule: sect=2 is the default midnight boundary, sect=1 the 23:00 Zi boundary. [Wenbu · calculation conventions](https://wenbu.app/methodology/)

- **Hour stem**: The heavenly stem of the hour pillar, derived from the day stem by a fixed rule; in the late Zi hour under Wenbu's default it already uses the next-day reference, so read it from the returned chart rather than assume it changes with the boundary setting. [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md) · [Wenbu · calculation conventions](https://wenbu.app/methodology/)

## Evidence notes

- Wenbu defaults to a 00:00 day boundary and offers a 23:00 Zi boundary as an option. — “默认在 00:00 换日（sect=2），也可选 23:00 子初换日（sect=1）” (fact); [Wenbu · calculation conventions](https://wenbu.app/methodology/)

- Under the default rule, the late-Zi hour stem still uses the library's next-day convention; the excerpt does not state the hour-stem rule after switching to the 23:00 boundary. — “默认规则下，晚子时的时干仍使用库的次日约定” (fact); [Wenbu · calculation conventions](https://wenbu.app/methodology/)

- A saved result should record the time zone and boundary settings, not just the eight characters. — “Save the date, time zone and boundary settings with the result.” (editorial); [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md)

## Sources

- [Wenbu · calculation conventions](https://wenbu.app/methodology/) — First-party implementation; not evidence of predictive accuracy; fetched 2026-10-31T07:00:35.677Z; complete response

- [lunar-typescript · official source](https://raw.githubusercontent.com/6tail/lunar-typescript/master/README.md) — Calculation implementation and conventions; fetched 2026-10-31T07:00:35.754Z; complete response

- [Wenbu · BaZi guide](https://wenbu.app/knowledge/en/bazi-basics.md) — Existing editorial and reproducible chart conventions; fetched 2026-10-31T07:00:35.781Z; complete response

[Chart the same record twice, changing only the day-boundary setting, and save both](https://wenbu.app/en/bazi/)