var mas = []; var obj1 = {a: "a1", b: "b1"}; mas.push(obj1); var obj2 = {a: "a2", b: "b2"}; mas.push(obj2); alert( mas.indexOf(obj1) );