(Please do note that I'm only on season two of the X-Files so I'm working off of season one Mulder here. I feel that's okay given they'd meet around the time season one would be happening.)
They meet in 1993 because Mulder hears about a guy who claims he was on a dinosaur infested island and immediately Must Interview. Ian's career just crumbled around him, so he's a mess, and what the hell? He might as well tell all to one more person.
Only then Mulder fully believes him. Without question. He sits and listens to this horrible, traumatizing story about this man who was hunted by dinosaurs, and watched people die, and was injured & left to die slowly and given no justice or credibility, all because everyone thought he was crazy. Because Mulder knows what that's like. He knows exactly what that's like. And when Ian is done talking, and more than a little drunk, Mulder crouches down in front of him, glass of water held out, and says, "It was very brave of you to stand up to them, Dr. Malcolm. I'm sorry it came to nothing." And Ian waits a minute, and then smiles, and dips the tip of one finger in the water. "Agent Mulder, have you ever heard of chaos theory?"
Ian tells Mulder more and more, listening to Mulder's own experience with his sister - "Damn aliens," he mutters, and knocks back a shot. Mulder's a little surprised at being believed, so he just stares for a second, and then chuckles. "Yeah. Damn aliens."
Eventually, they start meeting in bars. They become friends. Ian, being openly pan (shut up he's pan in my heart) eventually takes Mulder to a gay bar. Mulder's all "why would you bring me here? It's fine but I'm not like that." To which Ian replies, "You can believe in aliens, werewolves and dinosaurs but you draw the line at the possibility of your own attraction to men?"
(They hook up two nights later who said that.)
They watch sci-fi movies together, but nothing with monsters that bite. Ian's leg still cramps up sometimes, and the nightmares are horrible. Sometime in the midst of their closeness, Ian has a full break down, and he calls Mulder. Not anyone else. There is no one else. He calls Mulder, and Mulder comes, and makes it better. And the next thing they know, they're living together. For Ian's own good, Mulder insists. And it is. Mostly. But suddenly he's taking Kelly to gymnastics, he's staying the night in Ian's room, they're cooking dinner together, Ian is taking calls for him. And they're together, but they're not, because it's hard enough for them as it is - can you imagine if they were openly queer? It's still the 90s, after all. Ian could lose Kelly. Mulder could lose the X-Files. And Ian has made him promise never to risk too much without stopping to think if he should.
But when the second island surfaces, Mulder goes. He's so curious, and how can he refuse? He wants to prove it. For the X-Files, yes, but also for the sake of Ian's career. And then Ian, who can't even handle caricatures of what happened to him, goes back into that nightmare for the sake of Mulder. They escape by the skin of their teeth, Kelly in tow - and they decide, standing on the other side of hell for the second time each, that life is too short. They kiss and this time they let it mean something. And yeah, everyone's a bitch about it. It's the 90s, people suck. But Kelly's enthusiastic. The FBI rolls their eyes and looks the other way.
They'll always be Spooky Mulder and Mad Malcolm, and queers to boot, as it's turned out, but to each other they're Fox and Ian and that's good. That's enough.