Skip to content
WebViewGold Vibe Coding to App Store
English
Get WebViewGold

ChatGPT & Codex + share extension

Share into your ChatGPT & Codex app: links, text and photos from any other app

A bookmarking tool, a recipe box or a moodboard is only useful if saving takes one tap. With WebViewGold your ChatGPT & Codex app appears in the iOS and Android share sheet, and whatever the user shares (a link, a piece of text, a photo) arrives in your web app as the JavaScript variable sharedData. Your code decides what happens next: prefill a form, save it to your backend, or open an editor.

From $109 one-time per platform, or let our team do it all from $698.

  • Approval guarantee – or money back within 14 days
  • No coding needed
  • One-time payment, free updates
  • 24/7 human support
  • Made in Germany since 2014 · ISO 27001

How receiving shares works

iOS share extension

Users tap Share in Safari, Photos or another app and pick yours. WebViewGold passes the content to your web app in the JavaScript variable sharedData: text and links as plain text, images as Base64 strings.

Android share intent

Uncomment the prepared intent filters in AndroidManifest.xml (ACTION_SEND for text/plain and image/*, ACTION_SEND_MULTIPLE for several images) and the app icon shows up in Android's share dialog. Same variable, same handling: sharedData.

Your web app decides

Check for sharedData when the page loads, tell links, text and images apart, and route the user to a prefilled save screen. Nothing is stored until your own code sends it to Your own API or serverless functions, so the user stays in control.

Prompt for ChatGPT & Codex

Paste this into ChatGPT & Codex to implement the web-app side. Review the result, publish, then test inside the WebViewGold app.

Prompt for ChatGPT or Codex
Prompt for Codex: Implement a share-target flow for the WebViewGold native app and open a pull request. When navigator.userAgent contains my custom WebViewGold token, read the global sharedData on page load and again after one second; classify it as link (starts with http), image (long Base64 string, optionally with a data:image prefix) or text, and skip values already handled in this session. Navigate to a /save page that previews the item and offers Save and Cancel. Add a server endpoint POST /api/saves that requires the logged-in user, fetches link titles server-side with a timeout, stores images as files with our existing storage and writes a saves record. Add an optional Summarize toggle that uses our existing server-side OpenAI integration and stores the summary with the item after the user confirms it. Add unit tests for the classifier and an AGENTS.md section describing the sharedData contract. Never touch sharedData in regular browsers.

With a good optimized version of your web app you can have a stunning mobile app within a couple of minutes. Additionally to that the customer service is very nice and very helpful! I can just recommend WebViewGold :-)

Julian Koch · Co-Founder of DuelDonkey · CodeCanyon

What people share into apps like yours

A share target earns its place when one tap saves something the user would otherwise copy, switch apps and paste. Typical jobs:

Read-later and bookmarking

Share an article from Safari or Chrome, the app fetches title and preview image server-side, the user adds a tag and taps Save.

Recipes, places, products

A recipe link, a restaurant from a maps app, a product page: saved into a collection, a trip plan or a wishlist instead of a messy notes file.

Photos into a workflow

A receipt photo into an expense tracker, a screenshot into a bug report, a room photo into a moodboard or inventory. The image arrives as Base64, ready to upload.

Job posts and leads

Share a job listing or a profile link into a tracker or CRM and land on a prefilled "New entry" form with the URL already parsed.

Quotes and snippets

Highlighted text from any app becomes a note, a flashcard or a prompt for your AI feature, with the source link attached when the shared text contains one.

Add a share target to a ChatGPT & Codex app

About an hour, most of it on the save screen in your web app.

  1. Pick one job for the share

    Decide what a share does in your ChatGPT & Codex app: save a link, attach a photo, start a note. One clear action converts better than a menu of options.

  2. iOS: enable the share extension

    Follow iOS documentation to switch the share extension on in the WebViewGold Xcode project, then install the build on a real iPhone. The share sheet lists extensions of installed apps only, so the simulator is not a good test.

  3. Android: uncomment the intent filters

    In AndroidManifest.xml keep only the filters you actually handle: text/plain for links and text, image/* for one photo, SEND_MULTIPLE for several (Android documentation). A share target that accepts images but ignores them is a bad first impression.

  4. Read sharedData in ChatGPT & Codex

    Check typeof sharedData !== "undefined" on load and once more after a short delay. Values starting with http are links; long Base64 strings are images (JPEG data starts with /9j/, PNG with iVBORw0KGgo); everything else is text, possibly with a URL inside.

  5. Keep the draft through login

    If the user is signed out, store the shared item in sessionStorage, send them through your sign-in flow and restore the save screen afterwards. Never drop a share silently.

  6. Save and confirm

    Decode images to a Blob, resize and upload them, fetch link titles on the server and store the record in Your own API or serverless functions, then show a clear success state (a successhaptic:// call feels right here).

A sharedData handler for your web app

Framework-neutral; call checkSharedContent() once your app has mounted. Replace YourAppToken with the custom user agent you set in Config.swift (useragent_iphone, useragent_ipad) and Config.java (USER_AGENT).

javascript
var inApp = navigator.userAgent.indexOf("YourAppToken") !== -1;

function classifyShared(raw) {
  var value = String(raw).trim();
  var b64 = value.replace(/^data:image\/[a-z+]+;base64,/i, "");
  if (/^https?:\/\//i.test(value)) return { kind: "link", url: value };
  if (b64.length > 1000 && /^[A-Za-z0-9+\/=\s]+$/.test(b64.slice(0, 4000))) {
    return { kind: "image", base64: b64, mime: b64.indexOf("iVBORw0KGgo") === 0 ? "image/png" : "image/jpeg" };
  }
  var link = value.match(/https?:\/\/\S+/);
  return { kind: "text", text: value, url: link ? link[0] : null };
}

function base64ToBlob(b64, mime) {
  var bin = atob(b64.replace(/\s/g, ""));
  var bytes = new Uint8Array(bin.length);
  for (var i = 0; i < bin.length; i++) bytes[i] = bin.charCodeAt(i);
  return new Blob([bytes], { type: mime });
}

function checkSharedContent() {
  if (!inApp || typeof sharedData === "undefined" || !sharedData) return false;
  var fingerprint = String(sharedData).length + ":" + String(sharedData).slice(0, 64);
  if (sessionStorage.getItem("lastShare") === fingerprint) return false;   // already handled
  sessionStorage.setItem("lastShare", fingerprint);
  sessionStorage.setItem("pendingShare", JSON.stringify(classifyShared(sharedData)));
  window.location.href = "/save";                                         // your prefilled save screen
  return true;
}

window.addEventListener("load", function () {
  if (!checkSharedContent()) setTimeout(checkSharedContent, 1000);
});

What reviewers look for

A share target is one of the native integrations a Safari tab cannot offer on iOS, which makes it a strong point for Guideline 4.2. A few rules come with it.

  • 4.2

    Minimum functionality

    Show the share flow in a screenshot and mention it in the review notes ("Share a link from Safari to save it"). Reviewers only credit features they find.

  • 4.4

    Extensions

    Extensions should include real functionality, be disclosed accurately in your marketing text, and contain no marketing, advertising or in-app purchases. Keep the share flow a clean save action.

  • 2.5.16

    Related to your app

    Extensions should relate to the content and functionality of the app. A recipe app that accepts recipe links fits; a share target that just opens the home page does not.

  • 5.1.1

    Data you receive

    Shared photos and links can contain personal data. Upload only what the user confirmed, describe it in your privacy policy and declare it in App Privacy (photos, user content) and in the Google Play Data safety form.

Frequently asked questions

Can the app receive shares on both iOS and Android?

Yes. iOS uses a share extension and Android uses share intents; in both cases WebViewGold passes the content to your web app in the same JavaScript variable, sharedData, so one handler covers both platforms.

Which content types can users share into the app?

Text and links, and images, which arrive as Base64 strings. Android also has a prepared intent filter for several images at once. Other file types, such as PDFs, are not part of the documented API.

Can a web app or PWA do this without the native wrapper?

On Android, an installed PWA can register as a share target through the Web Share Target API in Chromium-based browsers. On iOS, Safari offers no equivalent for web apps, so a native share extension is the way to appear in the iPhone share sheet.

What if the user is not logged in when sharing?

Keep the shared item in sessionStorage, send the user through sign-in and bring them back to the save screen with the content still there. Losing a share after login is the most common bug in this flow.

Does a share extension guarantee approval under Guideline 4.2?

No single feature does. It is a strong, visible native capability; combined with push notifications, offline handling and an app-like layout it makes the case that your ChatGPT & Codex app is more than a website.

Three ways to get your app into the stores

Same result, different amount of work on your side. All three come with the approval guarantee and 24/7 human support.

Do it yourself

$109 per platform, one-time

The WebViewGold license: a finished Xcode or Android Studio project. Paste your URL, set name and icon, switch on features, build and submit. Free updates forever.

See plans on the main page

Cloud Builder

$349 per license, one-time add-on

No Mac, no Xcode, no Android Studio: configure in the browser, we build both apps in the cloud and hand them to App Store Connect and the Play Console.

How the Cloud Builder works Try the free demo

Full Service

$698 per platform $798

Send us your URL and icon. Our team configures, builds and delivers your app within 72 hours, white-label, with source projects. Both platforms for $1,158.

Full Service details Powered by WeSetupYourWebViewApp

Winter Sale prices valid until December 31, 2026.

Ready to ship your ChatGPT & Codex app?

App Store & Google Play approval guarantee – or your money back within 14 days

Rather hand it over? Full Service: we configure, build and deliver within 72 hours, from $698 per platform. Questions? Chat with us 24/7.

Refunds are granted under the conditions listed in our FAQ: a non-content rejection by Apple and/or Google, claimed within 14 days after purchase.