This is a 16-week double-blind, placebo-controlled (for colesevelam hydrochloride (HCl)) study in the type 2 diabetic subjects and pre-diabetic subjects. Diabetic participants will also be treated with open label, background,metformin HCl. Two-hundred sixty subjects with type 2 diabetes (T2DM) and 200 pre-diabetic subjects are planned to be be enrolled. Qualified subjects with T2DM will be randomized 1:1 to receive metformin HCl plus colesevelam HCl or metformin HCl plus placebo matching colesevelam HCl. Qualified pre-diabetic subjects will be randomized 1:1 to receive colesevelam HCl or matching placebo.