A compound of formula I: or pharmaceutically acceptable salts thereof, wherein: R 1 is optionally substituted imidazolyl; R 2 is optionally substituted phenyl, optionally substituted pyridinyl, optionally substituted pyrimidinyl, optionally substituted pyridazinyl or optionally substituted thiophenyl; R 3 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; or cyano; R 4 is hydrogen; C 1-6 alkyl; or hetero-C 1-6 alkyl; or R 3 and R 4 together with the atom to which they are attached may form a C 3-6 carbocyclic ring; R 5 is C 1-6 alkyl; hetero-C 1-6 alkyl; halo-C 1-6 alkyl; N-C 1-6 alkylamino; N,N-di-(C 1-6 alkyl)-amino; C 3-7 Cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; heterocyclyl-C 1-6 alkyl; aryl-C 1-6 alkyl; aryloxy-C 1-6 alkyl; -(CR a R b) m -C -R 8 wherein m is 0 or 1; R a and R b each independently is hydrogen; or C 1-6 alkyl; and R 8 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; C 3-7 cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; aryl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; heterocyclyl-C 1-6 alkyl; C 3-7 cycloalkyloxy; aryloxy; heteroaryloxy; heterocyclyloxy; C 3-7 cycloalkyloxy-C 1-6 alkyl; aryloxy-C 1-6 alkyl; heteroaryloxy-C 1-6 alkyl; heterocyclyloxy-C 1-6 alkyl; or -NR 9 R 10, wherein R 9 is hydrogen; or C 1-6 alkyl; and R 10 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; C 3-7 cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; aryl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; or heterocyclyl-C 1-6 alkyl; or R 4 and R 5 together with the atom to which they are attached may form a C 3-6 carbocyclic ring that is optionally substituted with hydroxy; or R 4 and R 5 together with the atom to which they are attached may form a C 4-6 heterocyclic ring containing one or two heteroatoms each independently selected from O, N and S; or R 3, R 4 and R 5 together with the atom to which they are attached may form a six-membered heteroaryl containing one or two nitrogen atoms, and which is optionally substituted with halo, amino or C 1-6 alkyl; and R 6, R 7 and R 8 each independently is hydrogen; C 1-6 alkyl; C 1-6 alkyloxy; halo; C 1-6 haloalkyl; or cyano. R 1 is optionally substituted imidazolyl; R 2 is optionally substituted phenyl, optionally substituted pyridinyl, optionally substituted pyrimidinyl, optionally substituted pyridazinyl or optionally substituted thiophenyl; R 3 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; or cyano; R 4 is hydrogen; C 1-6 alkyl; or hetero-C 1-6 alkyl; or R 3 and R 4 together with the atom to which they are attached may form a C 3-6 carbocyclic ring; R 5 is C 1-6 alkyl; hetero-C 1-6 alkyl; halo-C 1-6 alkyl; N-C 1-6 alkylamino; N,N-di-(C 1-6 alkyl)-amino; C 3-7 Cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; heterocyclyl-C 1-6 alkyl; aryl-C 1-6 alkyl; aryloxy-C 1-6 alkyl; -(CR a R b) m -C -R 8 wherein m is 0 or 1; R a and R b each independently is hydrogen; or C 1-6 alkyl; and R 8 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; C 3-7 cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; aryl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; heterocyclyl-C 1-6 alkyl; C 3-7 cycloalkyloxy; aryloxy; heteroaryloxy; heterocyclyloxy; C 3-7 cycloalkyloxy-C 1-6 alkyl; aryloxy-C 1-6 alkyl; heteroaryloxy-C 1-6 alkyl; heterocyclyloxy-C 1-6 alkyl; or -NR 9 R 10, wherein R 9 is hydrogen; or C 1-6 alkyl; and R 10 is hydrogen; C 1-6 alkyl; hetero-C 1-6 alkyl; C 3-7 cycloalkyl; aryl; heteroaryl; heterocyclyl; C 3-7 cycloalkyl-C 1-6 alkyl; aryl-C 1-6 alkyl; heteroaryl-C 1-6 alkyl; or heterocyclyl-C 1-6 alkyl; or R 4 and R 5 together with the atom to which they are attached may form a C 3-6 carbocyclic ring that is optionally substituted with hydroxy; or R 4 and R 5 together with the atom to which they are attached may form a C 4-6 heterocyclic ring containing one or two heteroatoms each independently selected from O, N and S; or R 3, R 4 and R 5 together with the atom to which they are attached may form a six-membered heteroaryl containing one or two nitrogen atoms, and which is optionally substituted with halo, amino or C 1-6 alkyl; and R 6, R 7 and R 8 each independently is hydrogen; C 1-6 alkyl; C 1-6 alkyloxy; halo; C 1-6 haloalkyl; or cyano.