The relationship between Josh Lyman and Donna Moss evolved slowly. They first met during Jed Bartlet's campaign. After the election, she served as Josh's assistant for years in the White House. The two often casually debated policy issues, with Josh voicing the Democratic party line and Donna voicing the kind of questions the typical voter might have.
They also constantly flirted with one another. After Donna encouraging Josh to ask out Joey Lucas, Joey told Josh that Donna was doing it in order to "cover herself with misdirection." Later in episode 2 '17 people', they have the whole red light scene when Josh said that if Donna were in an accident, he wouldn't stop for a beer, and Donna said that she wouldn't stop for red lights. Earlier in that series. Moreover, in 'The Portland Trip', Josh kept mocking her date and he later said that she looked "great in that dress."
As time went on it became clear that they cared deeply for one another: When Josh was shot (Season 1, 2) Donna went to his house every day to take care of him and bring him food, even restricting Josh's workload and preventing other staffers from coming until he got better, and Donna was the one who noticed Josh's symptoms of post-traumatic stress disorder. When Donna was injured by a roadside bomb in the Middle East, (late Season 5, early 6) the normally workaholic Josh dropped everything and stayed with her at the hospital in Germany. Josh brought Donna red roses, then found her gone (she had a blood clot.). Later, Donna's boyfriend, Colin Aryes, asked Josh about why he had flown "half way around the world" to be with Donna. Before this in the series 5 episode "Exit" C.J said that Donna stayed at the White House because of Josh. Amy Gardner noticed that Donna stayed as Josh's assistant without promotion and without exploring other opportunities that had opened up through years of being a White House insider. She also asked Donna if she was in love with Josh, in the series 4 finale.
After Donna quit as Josh's assistant, ("Impact Winter",) Josh was extremely upset and often found himself at odds with her since she had taken a job with the Russel campaign. In "The Ticket", Donna goes to Josh asking for a job as his deputy after Russel lost the nomination. He appears as if he wants to but thinks he shouldn't because of Donna's previous job, telling her, "I've got an airplane hangar out there filled with 500 strangers looking to me for direction; I've got a candidate who doesn't trust any of them and frankly neither do I, and if you think I don't miss you every day..." Donna is eventually hired by Lou as a spokeswoman to speak out against the attack ad on the Santos Campaign ("The Al Smith Dinner.")
When Donna brings Josh good news about some polling information showing that they are tied with Vinick, ("The Cold",) Josh kisses her, later saying that it was "inappropriate," but Donna disagrees, telling him that "it was bound to happen sometime." C.J. and Will Bailey later pick up on this, with Will telling her that it isn't inappropriate, after figuring out that "yours is Josh. You're not cryptic."
After sleeping with each other for a few weeks, they have issues defining their relationship. Donna gives Josh an ultimatum, saying that if they can't decide what they want their relationship to be in four weeks, then they clearly don't belong together.
When Sam Seaborn joins the campaign he forces Josh to go on a vacation and Josh asks Donna to join him. Several weeks later, on the morning of Santos' inauguration day, Josh and Donna wake up in bed together. From this, we can infer that they will be together for the long haul.