Possibly "World without end" (2010) by Fergus Gwynplaine MacIntyre, which was the answer to Short story with a woman made immortal by nanotechnology, sees end of Earth. The question matches your (terse) description:
Story focused around a woman, who for some reason had been injected /infected with a form of nanotechnology (I think that was the term used). These nanobots initially repaired any injury or damage the woman received. However as the years pass the nanobots have repaired so much of the woman that little or no flesh or blood exists, even replacing elements of the brain. The woman is still lucid and self aware.
The consequence of the repairing is the woman is now unable to die, and immortal (I think). As the years pass by she witnesses the end of the earth and the death of the sun in a supernova.
A young woman who is deliberately infected with life-preserving and repairing nanites.
As the linked question said, she gets injected after a "private" moment with a Uni student:
I was wearing a skimpy miniskirt and a halter. He saw the tracks all in the veins in my arms and my legs and he knew I was on the stuff. Then he jabbed a needle into my arm, injected something. It felt like fire in my blood, ooh I wanted it I wanted it.
She lives through the end of humanity
When she gets out of the lab in which she was tested upon, there is no one to be found.
Everybody was dead. I could see the big piles of snot and clothes where some people had been lately, and inside the buildings some little piles of dust where the snot had dried up. Most of the animals were dead too. Plenty of trees and plants, though. And insects. There were birds for a few weeks, then they all started dying.
and the death of the universe
After 12,000 years, she's still around, but the planet is changing. The sun is getting "bigger every day, and redder", to the point that "it's always summer". The air changes as well:
That was long long long ago. It's been getting harder to breathe for a long time now. It's not me that's changing, it's the air. It feels thickier than it used to be, and hotter, and stickier. I think there's something poison in it too, but not poison enough to kill me.
as the nanites constantly fix her.
There are lots of references to that; extracts:
Somehow the nano-things changed. A while back I noticed that I don't need to sleep any more. I've tried sleeping but it never comes. I'm tired all the time but I can't sleep.
I'm going blind in one eye. The left one. I can't remember the last time anything excited me, but I got excited and all when I noticed it. If something's wrong with me and now it doesn't heal, maybe those stinking nano-things are finally breaking down inside me.
I started bleeding and I hoped the nano-things would all leak out. While I watched it the whole bloody cut healed in about nineteen seconds. I heal faster now.
Found by searching this site for
[story-identification] nanobots immortal.