My main character is an accomplished computer programmer. He's created some best-selling games. He's done important work in relation to sumulation and VR programs, and he is the co-founder of a company that has a government contract. He and his partner made a pitch to get some financial backing, and it concerns creating a realistic simulated universe that people could live in. It would be indistinguishable from reality with the bonus of being able to upload human consciousness into the simulation. This is a holy grail idea for certain people above the government.
This programmer has no idea how to upload human consciousness into a simulation. It's just a theory that his partner seems more interested in. Our main character is just somebody who started doing this as a hobby. He has the idealistic belief that virtual reality simulations are a way to help make people's lives better. He sees it as a tool to fight depression. For a few hours a day in their free time, people can live the sort of life that they could never afford otherwise. He believes that what he's creating can be mass marketed to the people at a reasonable rate.
I would put the age of our main character somewhere in his 30s. He's been married for over a decade. Maybe she is his high school sweetheart. They are soulmates. While his latest sim is in development, his wife gets ill and is dying. He withdraws from the company to be with her. He creates an offshoot simulation of his main project that's just for his own personal use with his wife.
His simulation is big enough to give them a world that he and his wife can enjoy. She's not mobile anymore, so they spend their time in the simulation while she is still alive. At some point, she dies. This happens while she is in the simulation, but he doesn't realize what has happened at first. Her consciousness is in this simulation. He continues to spend time with her there after she dies, but in his mind she's a realistic copy. He doesn't realize that this is really her, and she thinks she is alive outside of the simulation..
He goes back to work, but he is still struggling to stay focused. His partner has tested consciousness uploads into the simulation on animals and has had some success. However, every time they try to put human consciousness into the simulation at the end of somebody's life, they fail. At some point, our main character's wife realizes that she is in a simulation. This was never something she wanted. She wanted to experience what comes next and feels she is being cut off from God. She feels this is unnatural. She will have the uncomfortable conversation with him. At first it's difficult for him to deal with it. He doesn't want to let her go once he knows that she is really there.
At some point, the guy's business partner accesses his personal simulated world and encounters his wife. It doesn't take very long for him to realize that this is her. It's not just a simulation of her, but it's actually her consciousness. He realizes that his business partner has held this information back from him. It was only through some sort of luck that this happened, and our main character has no idea how it occurred. His business partner wants to take this version of the simulation back to the company's lab to figure out exactly how this has happened.
By now, the man realizes that he doesn't want his wife to live in a way that she doesn't approve. He wants to free her from the program, but his partner and the government have other ideas. His goal is to free her. He realizes that the company's stated goal of wanting to create a simulation for uploading human consciousness is wrong. He realizes that this is also nothing more than an attempt by man to play God and control the consciousness of other people. I might introduce the idea that the government's plan is really to upload all of humanity's consciousness into a simulation. They want to eliminate almost all physical life in the name of saving the planet.
This will result in conflict at the end as he attempts to remove his wife from the simulation before they can figure out how she got there in the first place. This is the basic outline of the story. Characters include the man, his wife, the business partner and a couple of staff members. There will also be a couple of government alphabet agency types. There may be somebody who is above the government and pulling the strings. I think this story would be right on target for some of the things being discussed these days as technology continues to advance.