The British & Irish Lions back-rower has followed in the footsteps of another Wales star in George North, who has also decided to leave an Aviva Premiership side in Northampton to return to his homeland.
A latest Welsh Rugby Union's selection policy means players taking up new deals outwith a Welsh region must have won 60 caps to be eligible to play for their country.
Moriarty has decided to make the move to the Dragons to keep himself in the Wales frame and is looking forward to working under coach Bernard Jackman.
"Playing international rugby is the pinnacle of every player's career and with the new rules, it left me with no choice but to move to Wales to further my international ambitions, especially with the Rugby World Cup ahead," Moriarty said.
"I would like to thank Gloucester, specifically the players and coaching staff, for their continued support throughout my seven years at the club as well as Hartpury College, who provided me with the foundations to achieve my goals.
"Furthermore, I would like to thank the fans for their continued support. They have made the decision to move to Wales extremely difficult."