Four if you count the PS2 version, which was also significantly different from the original two. Ys IV is just... confusing.
Anyway, just wanted to hop in and say two things:
One, it's awesome to see such love for Ys on here. You guys rule.
And two, I agree that it's not really fair to compare Ys and Zelda, but mostly because that's not really where the biggest basis for comparison lies! The original Xanadu from 1985, Falcom's first breakout hit, is much more Zelda-like than Ys, and may even have been an inspiration for Zelda since it predated the game by two years. If you ever get a chance to check it out, I highly recommend it -- it's visually ugly, mechanically a bit clunky by today's standards and HARD AS NAILS (with ample opportunities to get yourself literally stuck so badly that you have no choice but to reset the game and play from scratch, for which it makes no apologies whatsoever)... but damn is it amazing for 1985. That was back when most of us were still playing Atari and Intellivision games -- when games that actually had endings were a rarity, and points were all most gamers thought about. And then Falcom came along and created something that was years ahead of its time, helping to shape the course of all JRPGs that followed.
The Falcom of the '80s was amazing. They were pretty much unstoppable innovators. And while they aren't quite blazing trails in the same way these days, the quality of their games really hasn't dropped at all in these past 30 years. They're a remarkable developer, and really exemplify everything I love about this medium.
-Tom