Compounds represented by the formulas wherein each symbol is as defined in the specification, and a prodrug thereof have a superior renin inhibitory activity, and are useful as agents for the prophylaxis or treatment of hypertension, various organ damages attributable to hypertension and the like.如下式所示之化合物及其前藥:;(I) (II);其中,各符號係如本說明書中所定義,且其具有優異的腎素抑制活性,且適用為高血壓以及由高血壓所造成之各種器官損傷等的預防劑或治療劑。