A heat exchanger that operates as an evaporator of a refrigeration cycle apparatus, comprising: a plurality of flat tubes extending in a horizontal direction and arranged in a height direction of the heat exchanger, the plurality of flat tubes being configured to allow refrigerant to flow therethrough; a connection portion in which a plurality of connection spaces are provided as spaces with which ends of the plurality of flat tubes are connected; and a refrigerant distributor connected to each of the plurality of connection spaces, wherein each of the plurality of flat tubes has a first side end portion located on a windward side, a second side end portion located on a leeward side, and a plurality of refrigerant passages arranged between the first side end portion and the second side end portion, and is inclined such that in the height direction, a position of the first side end portion is lower than a position of the second side end portion, the plurality of connection spaces are spaced from each other in the height direction, characterized in that a lower side of each of the plurality of connection spaces has a first region (37b1) located on the windward side and a second region (37b2) located on the leeward side, and is inclined such that in the height direction, a position of the first region (37b1) is lower than a position of the second region (37b2), an upper side of each of the plurality of connection spaces is formed to extend in the horizontal direction, not along the shape of the flat tube,and a first side and a second side of each of the plurality of connection spaces are formed to extend in the height direction, not along the shape of the flat tube. a plurality of flat tubes extending in a horizontal direction and arranged in a height direction of the heat exchanger, the plurality of flat tubes being configured to allow refrigerant to flow therethrough; a connection portion in which a plurality of connection spaces are provided as spaces with which ends of the plurality of flat tubes are connected; and a refrigerant distributor connected to each of the plurality of connection spaces, wherein each of the plurality of flat tubes has a first side end portion located on a windward side, a second side end portion located on a leeward side, and a plurality of refrigerant passages arranged between the first side end portion and the second side end portion, and is inclined such that in the height direction, a position of the first side end portion is lower than a position of the second side end portion, the plurality of connection spaces are spaced from each other in the height direction, characterized in that a lower side of each of the plurality of connection spaces has a first region (37b1) located on the windward side and a second region (37b2) located on the leeward side, and is inclined such that in the height direction, a position of the first region (37b1) is lower than a position of the second region (37b2), an upper side of each of the plurality of connection spaces is formed to extend in the horizontal direction, not along the shape of the flat tube,and a first side and a second side of each of the plurality of connection spaces are formed to extend in the height direction, not along the shape of the flat tube.