title: How to find Google Form ID
body: <h2>Update! The Form ID is in the web address.</h2>
  <p>Someone kindly pointed out to me (outside of Stack Overflow) that the Form ID which identifies the form can be found in the web address. Example:</p>
  <p><code>https://docs.google.com/forms/d/</code><strong>1y9XMjvZi_wlFC2FN64cdafIyGuM_7UOsn1Q61PXv5MQ</strong><code>/edit</code></p>
  <p>Where the bolded text is the Form ID.</p>
  <h2>Original:</h2>
  <p>Apologies in advance, as I am not an experienced script writer and may use improper jargon.</p>
  <p>But - I found the response to  <a href="https://stackoverflow.com/questions/35793303/how-to-get-element-id-in-google-forms">this question</a>  when googling about how to find the Form ID element in a Google Form, but the answer is old and my problem is similar. I have tried searching the &quot;Inspect Element&quot; data and still cannot identify the ID attribute. I've tried searching the code for:</p>
  <ul>
  <li>data-item-id=&quot;##########&quot;, or</li>
  <li>aria-describedby=&quot;i.desc.########## i3&quot;</li>
  <li>for=&quot;entry_XXXXXXX&quot;</li>
  </ul>
  <p>Still no luck. Does anyone have an updated suggestion for finding the Form ID? For reference, I am using the script below as my starting point. This is taken from a different/old form, but is similar in functionality so I was hoping to leverage it. I am trying to find my Form's ID (such as that as in line 6-7).</p>
  <pre class="lang-js prettyprint-override"><code> /**
   * @NotOnlyCurrentDoc
   * Limit OAuth scope to only current spreadsheet rather than all sheets in drive
   */ 
  
  function onSubmit(e) {
    var form = FormApp.openById('1eccBQ7Bs34Z54keGHeR8HDXmiP1UqxMi9vSDWNv6zgs');
  
    var sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Master');
  
     
    var data = sheet.getDataRange().getValues();
    //var urlCol = 26;
    var responses = form.getResponses();
    var timestamps = [], urls = [], resultUrls = [];
  
    for (var i = 0; i &lt; responses.length; i++) {
      timestamps.push(responses[i].getTimestamp().setMilliseconds(0));
      urls.push(responses[i].getEditResponseUrl());
    }
    for (var j = 1; j &lt; data.length; j++) {
  
      resultUrls.push([data[j][0]?urls[timestamps.indexOf(data[j][0].setMilliseconds(0))]:'']);
    }
    sheet.getRange(2, urlCol = 27, resultUrls.length).setValues(resultUrls);  
  
    return resultUrls;
  };
  </code></pre>