Generate button

Simplify your integration by using our interactive JavaScript button generator

docscurrentLast updated: September 30th 2021, @ 12:32:31 pm


Follow these steps to generate the JavaScript for the Log in with PayPal button:

  1. Configure button
  2. Generate JavaScript
  3. Modify JavaScript

Configure button

Modify the following fields to personalize the Log in with PayPal button. When you're finished, use the following dynamically generated Javascript.

(create or find an application; requires login)
(must match the environment of the application client id being used)
(if the application specifies a return URL, this field must match)

Generate JavaScript

Test the generated button. Once it works to your satisfaction, add the following generated HTML code into your site.

<span id="lippButton"></span>
Required fields are missing or malformed.

For recommendations on where to place this button on your site, see Button placement.

Modify JavaScript

You can optionally modify the generated JavaScript button code with the following parameters:

Parameter Required Description
appid

The application ID (the client ID from PayPal app creation).

Note: The application ID and client ID terms are used interchangeably.
authend Optional The authorization server URL: Pass sandbox for the test environment. Otherwise, for live, omit this value.
scopes The profile information requested (available scopes).
locale Language and country specifier.
buttonSize

The button size specifier:

  1. sm. Small.
  2. md. Medium.
  3. lg. Large.
buttonShape

The button shape specifier:

  1. pill. The default.
  2. rectangle
theme Optional

The button styling: PayPal blue or neutral.

returnurl

The page to return to after successful login.

responseType

The response type specifier:

  1. code
  2. id_token
  3. code & id_token
fullpage

The full page specifier:

  1. true
  2. false. Default is mini browser.
nonce Optional The nonce specifier can be a random number, for example 11111111.
  • If you don't provide this parameter, the return url redirection behavior is mini browser.
  • If you provide the paramenter with a random number, it will redirect to parent browser.

Next steps: