The degrees of freedom (DoF) of the MIMO Ychannel, a multi- way communication network consisting of 3 users and a relay, are characterized for arbitrary number of antennas. The converse is provided by cut-set bounds and novel genie-aided bounds. The achievability is shown by a scheme that uses beamforming to establish network coding on-the-fly at the relay in the uplink, and zero-forcing pre-coding in the downlink. It is shown that the network has min{2M(2) + 2M(3), M-1 + M-2 + M-3, 2N} DoF, where M-j and N represent the number of antennas at user j and the relay, respectively. Thus, in the extreme case where M-1 + M-2 + M-3 dominates the DoF expression and is smaller than N, the network has the same DoF as the MAC between the 3 users and the relay. In this case, a decode and forward strategy is optimal. In the other extreme where 2N dominates, the DoF of the network is twice that of the aforementioned MAC, and hence network coding is necessary. As a byproduct of this work, it is shown that channel output feedback from the relay to the users has no impact on the DoF of this channel.