# Where you sleep each night: bookings, options and gaps in your accommodation

> Kokai counts accommodation by nights: a trip from the 1st to the 5th has four, and each one is booked, in transit, with undecided options, empty or double-booked. Options are compared by price per night and by the median distance to what you have planned on those days. Once a booking is saved, each day of the plan starts at the hotel and ends there, and your device alerts you, offline, before free cancellation ends and on the eve of check-in.

- Address: https://kokai.app/en/alojamiento/
- Reviewed on: 2026-09-17
- Language: en

## In a nutshell

- **Unit:** The night, named after the date of its evening. A trip from the 1st to the 5th has four nights: 1, 2, 3 and 4.
- **States of a night:** Five: booked, in transit, undecided options, no accommodation and two bookings.
- **Comparing options:** Price per night (total divided by nights) and median straight-line distance to what is planned on those days.
- **Local alerts:** Free cancellation (two days before and on the day itself, at 10:00), «Mañana duermes en…» (“Tomorrow you sleep at…”, 18:00 the day before) and «Hoy dejas…» (“Today you leave…”, between 6:00 and 9:00).
- **From a PDF:** The confirmation is read on your device, without AI: dates, times, price, cancellation and address.
- **Searching elsewhere:** Links to nine websites with the place, dates and travellers filled in. Nothing is sent until you tap one.
- **What the AI receives:** Which nights are booked, where (name and coordinates) and the times. Never the price, the booking or your notes.

## The night as the unit

What usually goes wrong with accommodation (the unbooked night between two cities, the booking that starts a day late) is easier to spot when you count nights. That’s why each trip’s **Alojamiento** (“Accommodation”) screen (on your phone, inside «Más», “More”) opens with a strip of one box per night.

A night carries the date of the evening it starts: the “night of the 3rd” runs from the 3rd to the 4th. So a trip from the 1st to the 5th has **four nights** (1, 2, 3 and 4), because on the 5th you go home. Bookings work the same way: check-in on the 3rd and check-out on the 6th are three nights, and check-out has to be at least one day after check-in.

A stay counts **120 nights** at most: a check-out date typed with the wrong year can’t fill the screen with nights.

## Place and stay: the hotel and the nights in it

Kokai keeps two things apart:

- **The place** is the accommodation on the [map](https://kokai.app/en/mapa/): a pin in the Accommodation category, with its address, phone number and photos.
- **The stay** is a set of nights there: check-in and check-out, times, status (booked or option), total price and currency, free cancellation deadline, the booking document and your notes.

It isn’t a field of the place because the same hotel can come up twice in a trip (two nights in Lisbon on arrival and one after coming back from Porto) and several options can compete for the same nights. Nor is it a field of the document: an option has no confirmation yet, and the stay has to be describable to the AI without the booking reference.

A stay can be **accommodation** or **a night in transit** (a night train, a plane, a ferry), which has no place or times but counts as a night sorted. On a hotel’s card on the map, «Noches aquí» (“Nights here”) shows its stays and «Añadir noches aquí» (“Add nights here”) creates one.

## The states of each night

Each box in the strip has an icon and a name as well as a colour, and below it there’s a legend for the states that appear in that trip:

| State | When | What the app suggests |
| --- | --- | --- |
| Booked | A single accommodation booking covers that night. | Nothing: it’s sorted. |
| In transit | The only booking is a train, a plane or a ferry. | Nothing: it counts as a night with accommodation. |
| Undecided options | Nothing is booked, but there are one or more options. | Compare them and tap «Elegir esta» (“Choose this one”) on the one you book. |
| No accommodation | No bookings and no options. | «Falta alojamiento para…» (“Accommodation missing for…”), with «Añadir alojamiento» (“Add accommodation”), «Añadir una opción» (“Add an option”), «Es una noche en tránsito» (“It’s a night in transit”) and links to search elsewhere. |
| Two bookings | Two booked stays cover the same night. | A warning: «Tienes dos reservas para… Si no es a propósito, cancela una.» (“You have two bookings for… If that’s not on purpose, cancel one.”) |

Kokai also flags **bookings that fall outside the trip**, with a night beyond its dates: either the trip’s dates or the booking’s are wrong. The strip also appears in the trip summary, with “N of M with accommodation”.

### Example: Five nights in Lisbon and Porto

A trip from October 1 to 6 has five nights. You save a hotel in Lisbon from the 1st to the 3rd, a night train on the 3rd and two apartments in Porto, not yet booked, for the 4th and 5th.

- **Nights 1 and 2:** Booked (the Lisbon hotel).
- **Night 3:** In transit (the train).
- **Nights 4 and 5:** Undecided options (the two apartments).
- **Summary:** 3 of 5 with accommodation.

When you tap «Elegir esta» on one apartment, nights 4 and 5 become booked and the other one moves down to “options you didn’t choose”, where it stays within reach.

## Comparing options: price per night and the median distance

Each undecided option shows two figures, designed to compare accommodation across stays of different lengths:

- **Price per night**: the total price divided by its nights. An apartment at €390 for three nights comes to €130 a night.
- **Closeness**: «A unos… de lo que tienes planeado esos días» (“About… from what you have planned on those days”). It’s the median of the straight-line distances from the accommodation to each place in the [plan](https://kokai.app/en/plan/) on those nights and on the check-out day.

If those days have nothing planned, it measures against your **must-see** places, and if there are none, against **all your places**. Accommodation never counts, and the option has to be placed on the map. These are straight-line distances: they’re for comparing, not for knowing how long it will take you.

It uses the **median**, the middle value once the distances are sorted, because almost every trip has one place far from the rest and the average gets dragged along by it.

### Example: A hotel in the Baixa and a day trip to Sintra

Three nights in Lisbon with seven places planned, one of them Palácio da Pena, in Sintra. You compare an option in the Baixa with one in Benfica. Straight-line distances, rounded:

| Place | From the Baixa | From Benfica |
| --- | --- | --- |
| Elevador de Santa Justa | 0.2 km | 6.8 km |
| Sé de Lisboa | 0.4 km | 7.4 km |
| Castelo de São Jorge | 0.5 km | 7.1 km |
| Time Out Market | 0.8 km | 6.8 km |
| LX Factory | 3.7 km | 5.6 km |
| Mosteiro dos Jerónimos | 6.2 km | 5.9 km |
| Palácio da Pena (Sintra) | 23.6 km | 17.0 km |
| **Average** | 5.1 km | 8.1 km |
| **Median** | 0.8 km | 6.8 km |

With the average, the Baixa would seem to be “5 km from everything”, when four of the seven places are less than a kilometre away: Sintra’s 23.6 km weigh more than the other six put together (11.8 km). The median, 0.8 against 6.8 km, tells you what you’ll actually notice on foot.

## Each day of the plan starts and ends at your accommodation

With a booked stay, each day of the plan starts at the previous night’s accommodation and ends at that night’s. Only bookings count: an undecided option isn’t somewhere to set off from.

- At the top of the day: «Desde…» (“From…”) with the accommodation’s name, or **«Sales de…»** (“You leave…”) with «hasta las 11:00» (“until 11:00”) if you check out that day.
- At the bottom of the day: «Duermes en…» (“You sleep at…”), or **«Entras en…»** (“You check in at…”) with «desde las 15:00» (“from 15:00”) on the day you arrive somewhere new. On a night in transit, «Esta noche: Tren nocturno a Viena» (“Tonight: Night train to Vienna”).
- If that night of the trip has nothing booked: «Sin alojamiento para esta noche» (“No accommodation for tonight”), with a link to the Accommodation screen.
- Journeys from the hotel and back to it count towards the day’s total.

When the AI suggests [the plan](https://kokai.app/en/plan/), it groups each day’s places near the accommodation and allows for check-out and check-in on the day you change hotels.

## Accommodation alerts

Your device schedules them as local notifications, with no server and no connection, by its own clock. Only for **booked** stays of the accommodation type.

| Alert | When | What it says |
| --- | --- | --- |
| «Puedes cancelar gratis… hasta el…» (“You can cancel for free… until…”) | Two days before the free cancellation deadline, at 10:00. | That if you’re going to change plans, now is the time. |
| «Hoy es el último día para cancelar gratis…» (“Today is the last day to cancel for free…”) | On the day of the deadline, at 10:00. | That tomorrow cancelling may cost money. |
| «Mañana duermes en…» (“Tomorrow you sleep at…”) | The day before check-in, at 18:00. | The check-in time, the booking reference and the address, if it has them. |
| «Hoy dejas…» (“Today you leave…”) | On check-out day, two hours before the check-out time, never before 6:00 or after 9:00. With no check-out time, at 8:00. | The latest time you can leave, and a reminder to check you haven’t left anything behind. |

### Example: When «Hoy dejas…» arrives

- **Check-out by 11:00:** Alert at 9:00.
- **Check-out by 10:00:** Alert at 8:00.
- **Check-out by 7:00:** Alert at 6:00 (not earlier).
- **No check-out time:** Alert at 8:00.

Across all your reminders, for all your trips, 60 at most are scheduled, the nearest first.

> You enter the cancellation deadline yourself in «Cancelación gratis hasta» (“Free cancellation until”), or it comes from the PDF. Check it on the website where you booked: Kokai can’t know if it has changed.

## During the trip: «Esta noche duermes en…» (“Tonight you sleep at…”)

While the trip is under way, the [On the road](https://kokai.app/en/en-ruta/) screen («En ruta») shows the **«Esta noche duermes en»** (“Tonight you sleep at”) card at the top, with the accommodation’s name, the check-in time if you arrive today and, if your position is known, the distance to it.

- **«Volver al alojamiento»** (“Back to the accommodation”), if the accommodation is placed on the map, opens Google Maps with directions to the hotel. This one does need a connection.
- **«Enseñar la dirección»** (“Show the address”) displays in large type, for a taxi driver or at reception, the name, the address (or the coordinates, if it has none), the phone number and the booking reference.

All of that comes from your device and **works offline**.

## Adding a booking from its PDF

With «Desde el PDF de la reserva» (“From the booking PDF”), Kokai reads the confirmation on your device, without AI: provider, booking reference, dates and times, price, free cancellation and address. Which confirmations it understands is covered in [Booking PDFs](https://kokai.app/en/pdf-de-reservas/). If it’s accommodation with dates, it saves it in Documents and links it, in this order:

1. to the stay that already had that document;
2. to the option for that same hotel on those nights, which becomes booked;
3. to a new stay. The hotel is looked up by name among the trip’s places and, if it isn’t there, by its address in OpenStreetMap (Nominatim). Offline, it stays unplaced until you tap «Situarlo en el mapa» (“Place it on the map”).

It only fills in empty fields, and when it’s done it tells you what it read («Leído en este dispositivo: …, 3 noches. Revisa que esté bien.», “Read on this device: …, 3 nights. Check it’s right.”).

## What happens when you delete

| You delete | What happens to the nights |
| --- | --- |
| The hotel on the map | The nights **aren’t deleted**: they stay booked but “unplaced”, with their name, price and cancellation. Deleting a duplicate pin can’t leave a gap in the trip. |
| The booking in Documents | The stay stays booked, without the link to the document. |
| The stay | Those nights are removed from the trip. The accommodation stays on the map and the booking in your documents. |

## Check-in and check-out in Google Calendar (soon)

With Google Calendar connected, each booked accommodation will have two events in the “Kokai” calendar: «Entrada: …» (“Check-in: …”) and «Salida: …» (“Check-out: …”), half an hour long at their time or all-day if there’s no time, marked as free, with the address and, in the description, the booking reference and your notes. It’s built, but can’t be used yet: the Google connection still has to be registered.

## Searching for accommodation on other websites

Each night without accommodation, and the «Buscar en otras webs» (“Search other websites”) button, offer links to nine websites (Booking.com, Airbnb, Expedia, Hotels.com, Vrbo, Agoda, Trip.com, Kayak and Google Hotels) with the place, dates and travellers filled in, which you can change first. Kokai doesn’t connect to any of them: it only builds the link, and nothing goes out until you tap one. Each link is explained in the guide [Open Booking.com, Airbnb or Expedia with your dates already filled in](https://kokai.app/en/buscar-alojamiento/).

If a version of the app is built with affiliate links, it says so next to them («Algunos son enlaces de afiliado…», “Some are affiliate links…”). Without that sentence, they carry no affiliate tag. More in [the guide](https://kokai.app/en/buscar-alojamiento/#afiliados).

## What the AI knows about your accommodation

If you use [AI](https://kokai.app/en/ia/), for each **booked** stay it receives the nights, the name, the coordinates and the times (or “in transit”), plus the nights still unbooked. **Never** the price, the booking, the reference or your notes, nor the options you’re comparing. More in [Your data](https://kokai.app/en/tus-datos/).

## Check it yourself

1. Open a trip with dates and, on your phone, tap «Más» (“More”) and then «Alojamiento» (“Accommodation”). At the top is the strip with one box per night.
2. On a night without accommodation, tap «Añadir una opción» (“Add an option”), look it up in «Buscar el alojamiento en el mapa» (“Find the accommodation on the map”), pick the result and enter a «Precio total» (“Total price”). Tap «Guardar» (“Save”).
3. Add another option for the same nights, in another neighbourhood. Under «Opciones sin decidir» (“Undecided options”) each card shows the price per night and «A unos… de lo que tienes planeado esos días» (“About… from what you have planned on those days”).
4. Tap «Elegir esta» (“Choose this one”) on one: its nights become booked and the other moves down to the options you didn’t choose.
5. Edit the booking and set a «Hora de salida (hasta)» (“Check-out time (by)”) and a date in «Cancelación gratis hasta» (“Free cancellation until”). Go to the plan: check-out day starts with «Sales de…» (“You leave…”).
6. With the trip under way, open «En ruta» (“On the road”) and tap «Enseñar la dirección» (“Show the address”) on the «Esta noche duermes en» (“Tonight you sleep at”) card.

## Frequently asked questions

### Can I have two bookings on the same night?

Yes, sometimes it’s on purpose (two rooms in different hotels, or a backup booking). Kokai marks it as “Two bookings” and warns you so that, if it isn’t, you can cancel one in time.

### Will it remind me about free cancellation if I’m offline?

Yes. Accommodation alerts are scheduled by your device, with no server. You need to have given Kokai permission to show notifications, and the stay has to be booked.

### Does Kokai book for me or compare prices across websites?

No. It doesn’t connect to any accommodation website: it opens their search with your dates, and you enter the price yourself, or it’s read from the confirmation PDF when you book.

## Sources and references

- [Median](https://en.wikipedia.org/wiki/Median) — Wikipedia
- [Arithmetic mean](https://en.wikipedia.org/wiki/Arithmetic_mean) — Wikipedia
- [Events: the events resource in the Google Calendar API](https://developers.google.com/workspace/calendar/api/v3/reference/events) — Google for Developers
- [Nominatim Usage Policy](https://operations.osmfoundation.org/policies/nominatim/) — OpenStreetMap Foundation
- [PDF.js](https://mozilla.github.io/pdf.js/) — Mozilla
- [ISO 8601 (YYYY-MM-DD dates)](https://en.wikipedia.org/wiki/ISO_8601) — Wikipedia

