Short answer
Shanghai to Xiamen is one of the easiest long runs on China's east coast. High-speed trains leave Shanghai Hongqiao for Xiamen North in about 5 to 8 hours, over roughly 1,100 km of coastal line. The quickest services come in a little over five hours; the average lands around six to seven.
There is no dedicated overnight sleeper, and the route does not need one. Around thirty departures a day run from early morning into the afternoon, which makes this a long half-day rather than a trip that eats a night. The overnight sleeper trains on this coast are long-distance services bound for Guangdong that leave Shanghai in the evening — useful if you are continuing south, marginal if Xiamen is your destination.
Book on the 12306 app or website, where a foreign passport works for the booking and the gate. Tickets usually open around two weeks before departure at the time of writing, so check the official channel for the current window before you build a plan around it.
The stations at each end
Shanghai has more than one station on this corridor, and several trains make their first stop well outside the city. The station on your ticket is the one that matters.
| Station | Role on this route | Getting in and out |
|---|---|---|
| Shanghai Hongqiao (上海虹桥) | The starting point for most services, and the busiest rail hub in the city | Metro lines 2, 10 and 17; directly connected to Hongqiao Airport |
| Shanghai South (上海南) | Used by some G and D departures, including several of the slower services | Metro lines 1, 3 and 15 |
| Outlying stops (Songjiang, Jinshan North) | Some trains call here before leaving the Shanghai area | Reachable by regional rail and metro; usually not worth the detour |
| Xiamen North (厦门北) | Where most trains finish, in Jimei across the bay from the old town | Metro Line 1 to the centre, BRT routes, taxis |
| Xiamen Station (厦门站) | Island-side terminus used by a number of services, closest to Zhongshan Road | Downtown; a short ride from the Gulangyu ferry piers |
Hongqiao is the default. If your booking says Shanghai South, factor in the extra cross-city transfer — it is a genuine difference, not a formality.
How long the journey takes
The gap between the fastest and slower trains on this corridor is nearly three hours, which is more than enough to change what the day looks like.
| Service type | Typical duration | Notes |
|---|---|---|
| Fastest G trains | A little over 5 hours | Few stops, often leaving and arriving at the busiest stations |
| Most G services | About 6 to 7 hours | The bulk of the timetable; the sensible planning figure |
| Slower G and D services | About 7 to 8 hours | More stops, sometimes cheaper, and they reach Xiamen in the evening |
Departures cluster between early morning and mid-afternoon, because the trains need to complete the run the same day. That means an early start is the normal shape of this trip, and the last useful departures leave Shanghai before the afternoon is out. Confirm the current spread of departure times on the 12306 app or official channel.
Is there an overnight sleeper?
Not on this route as a product. Every Shanghai to Xiamen service is a daytime, seated high-speed train, which is why the timetable empties out in the afternoon rather than filling up with berths.
The overnight trains that do run down this coast are long-distance D services heading for Guangdong, and they leave Shanghai Hongqiao in the evening. If your plan is to continue past Xiamen toward Shantou, Shenzhen or Guangzhou, one of those may suit you. Whether a given service stops somewhere convenient for Xiamen, and at what hour, is worth checking on the app rather than assuming.
For the comparison that actually matters: if you want a genuine one-night sleeper in China, the corridor to look at is shorter and busier — Beijing to Shanghai is the classic example, and the beds that leave in the evening arrive before breakfast.
Seat classes on this corridor
Two families of train share the line, and the seating language differs between them.
| Class | Layout | Worth it when |
|---|---|---|
| Second class | 3+2 seating on both G and D trains | The default; perfectly comfortable for six hours |
| First class | 2+2, wider seat, more recline | A modest upgrade that pays off on the full eight-hour runs |
| Business class (G trains only) | 2+1 shell or lie-flat seat | Costs several times second class; rarely worth it on a half-day trip |
| Standing or no-seat tickets | Sold on some peak services | Best avoided on a journey this long |
How each class differs in seat width, luggage space and power sockets is set out in our train seat classes guide.
Booking with a foreign passport
12306 is the railway's own channel, and it is the one to use. A passport is an accepted document for the account and the ticket, and the booking is tied to the passport number you enter, so you travel on the document you booked with.
Two things catch visitors out. The sales window is short — around two weeks before departure at the time of writing — and it has moved repeatedly, so check the official channel rather than trusting a guide written a year ago. And fares are not always a flat number: some departures on the coastal high-speed lines sell below the full fare, which is why two trains on the same day can offer the same class at different prices.
Third-party resellers work and charge a fee for it. They are a fallback, not the railway's price. The setup steps, including switching the interface to English, are in our 12306 in English guide.
On board and on arrival
Tickets are electronic. Nothing is collected at a counter: the passport is scanned at the gate, or read by a member of staff at a staffed lane where the automatic gates struggle with foreign documents.
- Luggage. Overhead racks and shelves at the carriage ends take a normal suitcase. Boarding time at the origin station is generous; the intermediate stops are not, and you may have under two minutes on the platform.
- Food. A trolley makes its way through the train, and some services have a dining car. Station food before boarding is more reliable on the earliest departures, when the trolley can take an hour to reach your carriage.
- Scenery. The interesting part is the last two hours: the line runs down the Fujian coast, cuts through hills and crosses the bay into Xiamen. The first stretch out of Shanghai is flat, industrial and forgettable.
- Arrival. At Xiamen North, follow the metro signs rather than the taxi rank if the traffic is heavy. Metro Line 1 runs across the bay into the centre.
Reading the departure boards, finding the right waiting hall and clearing the security check without speaking Mandarin is covered in our train station guide.
Train or plane
A flight covers the distance in a fraction of the time on paper. The gap narrows once you count the trip to Pudong or Hongqiao's domestic terminal, the check-in, the baggage wait at the far end, and the run from Xiamen's airport into town.
The train starts at Hongqiao, which is already on the metro, and finishes at a station that is also on the metro. No connection to the airport, no luggage carousel, no second security line. On a journey under seven hours, that stack of small advantages is usually worth more than the flight-time difference.
One more consideration: the coastal high-speed line passes through cities that reward a stop. Splitting the trip over two days, with a night in Fuzhou or Ningbo, turns a travel day into part of the itinerary. You would buy separate tickets for each leg, both on the same app.
Frequently asked questions
How long is the train from Shanghai to Xiamen?
Most high-speed services take between about 5 and 8 hours. The quickest departures cover the roughly 1,100 km in a little over five hours and the average lands around six to seven. Slower D services with more stops sit at the top of the range. Confirm the exact departure on the 12306 app or official channel.
Is there an overnight train from Shanghai to Xiamen?
Not as a dedicated route. This is a daytime corridor with around thirty departures a day, all of them seated high-speed trains. The overnight sleeper services on this coast are long-distance D trains bound for Guangdong that leave Shanghai in the evening; whether one of them suits a Xiamen arrival is something to check on the 12306 app.
Which Shanghai station do trains to Xiamen leave from?
Most leave from Shanghai Hongqiao Railway Station, which is joined to Hongqiao Airport and served by metro lines 2, 10 and 17. Some services start at Shanghai South, and a few call at outlying stations such as Shanghai Songjiang and Jinshan North. The departure station printed on your booking decides where you go.
Which station in Xiamen do I arrive at?
The majority of services terminate at Xiamen North Railway Station in Jimei, connected to the centre by Metro Line 1 and BRT routes. A number of trains also serve Xiamen Station on the island, closer to Zhongshan Road and the Gulangyu ferry piers. Check which station your ticket names.
Can I book this train with a foreign passport?
Yes. A passport is an accepted identity document on the official 12306 app and website, and the e-ticket is linked to the passport number you enter. Travel with that same passport, scan it at the gate, and use a staffed lane if the automatic gate cannot read it.
How early can I buy tickets for this route?
The online sales window is short — around two weeks before departure at the time of writing — and it has changed repeatedly in recent years. Check the current window on the official channel. On Spring Festival, Labour Day and October Golden Week dates, this corridor can sell out within hours of tickets being released.
Is it cheaper or faster to fly Shanghai to Xiamen?
Faster, yes; cheaper, usually not. The flight is short, but both airports sit outside the city centre, so the door-to-door saving is smaller than the flight time suggests. For a journey under seven hours by rail, starting at Hongqiao, most visitors find the train the simpler option.
Can I break the journey, for example with a night in Fuzhou?
Yes, and it is a reasonable way to split the trip. The corridor runs down the Fujian coast through cities including Ningbo and Fuzhou, all served by frequent trains. Each leg needs its own ticket — buy both in the same app in advance, because the short connecting legs are the first to sell out on peak dates.
Related reading
Xiamen sits roughly halfway down the coast, so most trips here pair it with either the Yangtze delta to the north or the Pearl River delta to the south-west. The southern link, on toward Shantou and Guangdong, is the one where an overnight service can actually save you something.
Compiled from published corridor schedules, station information and ticket-sales rules for the Shanghai–Xiamen coastal high-speed line, cross-checked 30 September 2026 from two independent timetable sources. Journey durations, fares and the ticket sales window change with each railway timetable adjustment, and departure times on a corridor this busy are revised several times a year — the 12306 app at the time you book is the authoritative version. Nothing on this page is financial or legal advice.