<script> var array = ['1','2','3']; var json = JSON.stringify(array); alert(json); </script>