Question: I'm going to a concert to Vienna on Saturday (two days). I just realized that there aren't any trains back to my home in the night so I'd have to wait til the morning until the first train leaves again (5.43 AM).

I don't know when the concert will end, but expect it to be somewhere between midnight and 2 AM. 

Now, I don't want to spend 40 € on a hotel room, especially when I can only "book in" in the middle in the night and have to leave really early. 

Is there any safe space in Vienna for a young woman to stay for a couple of hours in the middle of the night? I don't need to sleep, I just don't want to get raped. 
Are train stations safe there? Or are there any cafés which are open 24/7? MacDonalds?

Answer: 
Update May 2022: both McDonald's are closed overnight.

---

There are only 2 McDonald's in/near Vienna that are open 24/7 (and even on [the Chistmas and New Year holidays](https://www.mcdonalds.at/downloads/oeffnungszeiten_2018.pdf)):

* at the aiport, Objekt 115
* in Wiener Neustadt, Pottendorfer Str. 45

Their [restaurant finder](https://www.mcdonalds.at/restaurant-finder) has on option to restrict the search to restaurants that are open 24/7: go to "Detailsuche", tick "24h geöffnet".

All the Burger Kings and KFCs are closed during the night.

As @FDMS notes, the only transit service to the airport that runs 24/7 (though very infrequently) is the [Vienna Airport Lines](https://www.viennaairportlines.at) bus service ([network map](https://www.viennaairportlines.at/en/info/1144)), which costs 6.5 € per direction. The last train to Wiener Neustadt, which is over one hour away from Vienna, leaves at 01:01 from the main train station (Hbf).
As you are staying on a weekend, there will be plenty of bars, clubs and other entertainment locations open till the early morning. Some of them may be loud, some quiet, so you can pick depending on what you are likely to be in a mood in after the concert.

Here's an english website listing many options: <https://www.wien.info/en/lifestyle-scene/nightlife>

Note that in general, Vienna is considered a very safe city. So you should most likely be fine no matter where you stay, but as everywhere else, a public place is a good option.