A refrigeration cycle apparatus comprising: an indoor unit comprising at least an indoor heat exchanger; a plurality of outdoor units (50a, 50b) connected in parallel to each other and connected to the indoor unit; and a controller configured to control the plurality of outdoor units (50a, 50b), each of the plurality of outdoor units (50a, 50b) including an outdoor heat exchanger (2a, 2b), a compressor (1a, 1b), and a sensor (5a, 5b) configured to detect a quantity of refrigeration oil in the outdoor unit (50a, 50b), the refrigeration cycle apparatus further comprising at least one expansion device (3a, 3b), the indoor heat exchanger, the expansion device (3a, 3b), the outdoor heat exchanger (2a, 2b), and the compressor (1a, 1b) constituting a refrigerant circuit through which refrigerant circulates, the outdoor heat exchanger (2a, 2b) and the compressor (1a, 1b) being included in each of the plurality of outdoor units (50a, 50b), as an operation mode, the controller having a first operation mode in which a part of the plurality of outdoor units is operated and another outdoor unit is stopped, and a second operation mode in which all of the plurality of outdoor units (50a, 50b) are operated, in the first operation mode, when the quantity of refrigeration oil in a compressor of an operating outdoor unit is larger than a prescribed quantity and when an operating time of the operating outdoor unit does not exceed a prescribed time, the controller being configured to maintain operation of the operating part of the plurality of outdoor units, in the first operation mode, when the quantity of refrigeration oil in the compressor of the operating outdoor unit is larger than the prescribed quantity and when the operating time of an operating outdoor unit exceeds the prescribed time, the controller being configured to stop the operating outdoor unit and make a switch to bring the stopped outdoor unit of the plurality of outdoor units (50a, 50b) into operation,and wherein in the second operation mode, when the quantity of refrigeration oil in the compressor of a first outdoor unit of the plurality of outdoor units (50a, 50b) is smaller than the prescribed quantity, the controller is configured to control the plurality of outdoor units (50a, 50b) so as to increase a discharging refrigerant flow rate of the compressor of the first outdoor unit and so as to decrease a discharging refrigerant flow rate of the compressor of a second outdoor unit of the plurality of outdoor units (50a, 50b). an indoor unit comprising at least an indoor heat exchanger; a plurality of outdoor units (50a, 50b) connected in parallel to each other and connected to the indoor unit; and a controller configured to control the plurality of outdoor units (50a, 50b), each of the plurality of outdoor units (50a, 50b) including an outdoor heat exchanger (2a, 2b), a compressor (1a, 1b), and a sensor (5a, 5b) configured to detect a quantity of refrigeration oil in the outdoor unit (50a, 50b), an outdoor heat exchanger (2a, 2b), a compressor (1a, 1b), and a sensor (5a, 5b) configured to detect a quantity of refrigeration oil in the outdoor unit (50a, 50b), the refrigeration cycle apparatus further comprising at least one expansion device (3a, 3b), the indoor heat exchanger, the expansion device (3a, 3b), the outdoor heat exchanger (2a, 2b), and the compressor (1a, 1b) constituting a refrigerant circuit through which refrigerant circulates, the outdoor heat exchanger (2a, 2b) and the compressor (1a, 1b) being included in each of the plurality of outdoor units (50a, 50b), as an operation mode, the controller having a first operation mode in which a part of the plurality of outdoor units is operated and another outdoor unit is stopped, and a second operation mode in which all of the plurality of outdoor units (50a, 50b) are operated, a first operation mode in which a part of the plurality of outdoor units is operated and another outdoor unit is stopped, and a second operation mode in which all of the plurality of outdoor units (50a, 50b) are operated, in the first operation mode, when the quantity of refrigeration oil in a compressor of an operating outdoor unit is larger than a prescribed quantity and when an operating time of the operating outdoor unit does not exceed a prescribed time, the controller being configured to maintain operation of the operating part of the plurality of outdoor units, in the first operation mode, when the quantity of refrigeration oil in the compressor of the operating outdoor unit is larger than the prescribed quantity and when the operating time of an operating outdoor unit exceeds the prescribed time, the controller being configured to stop the operating outdoor unit and make a switch to bring the stopped outdoor unit of the plurality of outdoor units (50a, 50b) into operation,and wherein in the second operation mode, when the quantity of refrigeration oil in the compressor of a first outdoor unit of the plurality of outdoor units (50a, 50b) is smaller than the prescribed quantity, the controller is configured to control the plurality of outdoor units (50a, 50b) so as to increase a discharging refrigerant flow rate of the compressor of the first outdoor unit and so as to decrease a discharging refrigerant flow rate of the compressor of a second outdoor unit of the plurality of outdoor units (50a, 50b).