var myObj = {key1: "value1", key2: "value2", key3: "value3"}; var result = [], p; for (p in myObj) if (myObj.hasOwnProperty(p))result.push(p + ":" + myObj[p]); alert(result);