PHPackages                             jfbiswajit/php-bigquery - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. jfbiswajit/php-bigquery

ActiveLibrary[Database &amp; ORM](/categories/database)

jfbiswajit/php-bigquery
=======================

PHP BigQuery for Laravel is a seamless integration package that allows you to harness the power of Google BigQuery in your Laravel applications effortlessly. With a zero-configuration setup, plug and play this library to perform high-speed querying and advanced analytics on large datasets.

1.0.0(2y ago)15.4k↓32.9%MITPHP

Since Aug 2Pushed 2y ago1 watchersCompare

[ Source](https://github.com/jfBiswajit/php-bigquery)[ Packagist](https://packagist.org/packages/jfbiswajit/php-bigquery)[ RSS](/packages/jfbiswajit-php-bigquery/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

PHP BigQuery Package for Laravel
================================

[](#php-bigquery-package-for-laravel)

[![PHP BigQuery](https://camo.githubusercontent.com/75b50fd2299bd8eef449df752191ec4a58cb93e8c94fdd89726d1e99052662d6/68747470733a2f2f6d69726f2e6d656469756d2e636f6d2f76322f726573697a653a6669743a313030302f666f726d61743a776562702f302a736f33667348317777764c6d4b6375432e706e67)](https://camo.githubusercontent.com/75b50fd2299bd8eef449df752191ec4a58cb93e8c94fdd89726d1e99052662d6/68747470733a2f2f6d69726f2e6d656469756d2e636f6d2f76322f726573697a653a6669743a313030302f666f726d61743a776562702f302a736f33667348317777764c6d4b6375432e706e67)

Description
-----------

[](#description)

PHP BigQuery is a Laravel package that provides seamless integration with Google BigQuery using the `google/cloud-bigquery` library. This package allows you to interact with BigQuery effortlessly and perform various operations on datasets and tables.

Installation
------------

[](#installation)

To get started with PHP BigQuery in your Laravel project, follow these steps:

1. Install the package via Composer:

```
composer require jfbiswajit/php-bigquery
```

2. Generate a service account key for your Google Cloud project. Follow the steps below to create and download the key in JSON format:

### Generate Service Key

[](#generate-service-key)

1. Go to the Google Cloud Console by visiting  and sign in with your Google account.
2. Select the project where your BigQuery data is located from the project selector at the top of the page.
3. In the left-hand menu, click on "IAM &amp; Admin," and then select "Service Accounts" from the sub-menu.
4. Click on the "CREATE SERVICE ACCOUNT" button to create a new service account.
5. Enter a name and description for the service account. Leave the "Service account ID" field as it is, as it will be automatically generated.
6. In the "Role" dropdown, select the appropriate role that grants the service account the necessary permissions to access your BigQuery data. For example, you can choose the "BigQuery User" role for read access to datasets and tables.
7. Click on the "CREATE" button to create the service account.
8. Locate the newly created service account on the "Service Accounts" page. Click on the three dots (vertical ellipsis) to the right of the service account's entry, and then click on "Create key."
9. Choose the "JSON" key type and click on the "CREATE" button. This will download a JSON file containing the service account key to your computer.
10. Move the downloaded JSON key file to a secure location in your Laravel project. A common practice is to store it in the "storage" directory with the name "bigquery-credentials.json," but you can choose any suitable location. Just ensure that the file is not publicly accessible on your web server to keep your credentials secure.

### Finding Project ID

[](#finding-project-id)

To find your Google Cloud Project ID, follow these steps:

1. Go to the Google Cloud Console by visiting  and sign in with your Google account.
2. If you are not already in the project, use the project selector at the top of the page to select the project where your BigQuery data is located.
3. After selecting the correct project, you will see the project name displayed in the top-left corner of the Cloud Console.
4. Click on the project name (or the project ID, if it's shown next to the name) in the top-left corner. This will open the project details page.
5. On the project details page, you will find the "Project info" section. The "Project ID" will be listed there.

The Project ID is a unique identifier for your Google Cloud project and is used for various purposes, including accessing APIs, managing resources, and setting up credentials like we discussed for BigQuery.

Configuration
-------------

[](#configuration)

Once you have obtained the service account key and the Project ID, you can set the following environment variables in your Laravel project's `.env` file:

```
GOOGLE_APPLICATION_CREDENTIALS=/path/to/your/bigquery-credentials.json
GOOGLE_CLOUD_PROJECT_ID=your-project-id
```

Usage
-----

[](#usage)

With PHP BigQuery integrated into your Laravel project, you can use the package to interact with Google BigQuery and perform various data operations. The package provides an easy-to-use facade to access the functionalities.

```
// Example code to retrieve data from BigQuery
use JfBiswajit\PHPBigQuery\Facades\BigQuery;

$results = BigQuery::query('SELECT * FROM your_dataset.your_table');
```

For detailed usage and available methods, please refer to the package documentation.

Contribution
------------

[](#contribution)

Your contributions to this project are highly appreciated. If you encounter any bugs, have feature requests, or want to contribute to the codebase, feel free to submit a pull request or open an issue on GitHub.

License
-------

[](#license)

This package is open-source software licensed under the [MIT license](https://opensource.org/licenses/MIT).

Author
------

[](#author)

- Name: Biswajit Biswas
- Email:

---

Thank you for choosing PHP BigQuery for Laravel! We hope this package simplifies your BigQuery integration and data management tasks. If you have any questions or need assistance, please don't hesitate to reach out to the author or the community for support. Happy coding!

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 50% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1020d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2ee6503351779e5104b29aab9e650e31a93cfe5582d372bbfd78b1ca81f65070?d=identicon)[jfbiswajit](/maintainers/jfbiswajit)

---

Top Contributors

[![jfbiswajit](https://avatars.githubusercontent.com/u/42512360?v=4)](https://github.com/jfbiswajit "jfbiswajit (1 commits)")[![jfBiswajit](https://avatars.githubusercontent.com/u/42512360?v=4)](https://github.com/jfBiswajit "jfBiswajit (1 commits)")

### Embed Badge

![Health badge](/badges/jfbiswajit-php-bigquery/health.svg)

```
[![Health](https://phpackages.com/badges/jfbiswajit-php-bigquery/health.svg)](https://phpackages.com/packages/jfbiswajit-php-bigquery)
```

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[reliese/laravel

Reliese Components for Laravel Framework code generation.

1.7k3.4M16](/packages/reliese-laravel)[wildside/userstamps

Laravel Userstamps provides an Eloquent trait which automatically maintains `created\_by` and `updated\_by` columns on your model, populated by the currently authenticated user in your application.

7511.7M13](/packages/wildside-userstamps)[usmanhalalit/laracsv

A Laravel package to easily generate CSV files from Eloquent model.

6151.7M4](/packages/usmanhalalit-laracsv)[hipsterjazzbo/landlord

A simple, single database multi-tenancy solution for Laravel 5.2+

613270.0k1](/packages/hipsterjazzbo-landlord)[stancl/virtualcolumn

Eloquent virtual column.

826.8M13](/packages/stancl-virtualcolumn)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
