PHPackages                             rationalboss/gsheet-manager - 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. rationalboss/gsheet-manager

ActiveLibrary

rationalboss/gsheet-manager
===========================

Google spreadsheet client

v0.1.7(9y ago)0101MITPHP

Since Sep 3Pushed 9y ago1 watchersCompare

[ Source](https://github.com/rationalboss/gsheet-manager)[ Packagist](https://packagist.org/packages/rationalboss/gsheet-manager)[ RSS](/packages/rationalboss-gsheet-manager/feed)WikiDiscussions master Synced 2mo ago

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

Google Spreadsheet Client for PHP
=================================

[](#google-spreadsheet-client-for-php)

Google Spreadsheet Client for PHP. This requires "google/apiclient" package.

Get started
-----------

[](#get-started)

### 1. Get key file

[](#1-get-key-file)

1. Log in [Google Developper Console](https://console.developers.google.com)
2. Create new project
3. Create **Service Account** credentials in the project
4. Download key file as JSON

### 2. Create spreadsheet

[](#2-create-spreadsheet)

1. Create a new spreadsheet in [Google Drive](https://drive.google.com)
2. Authorize the email address, which is found as "client\_email" in key file, to read and edit.
3. Save the **file ID** from address bar.

### 3. Access by PHP

[](#3-access-by-php)

```
$client = Google_Spreadsheet::getClient("the/path/to/credential.json");
// Get the file by file ID
$file = $client->file("XXXxxxXXXXxxxXXXX");
// Get the sheet by title
$sheet = $file->sheet("Sheet1");
// Flush all rows in the sheet
var_dump($sheet->items);
```

Usage
-----

[](#usage)

### Select rows

[](#select-rows)

```
// Array
$items = $sheet->select(array("id" => "1"));
// Closure
$items = $sheet->select(function($row){
	return (int) $row["age"] < 30;
});
```

### Insert a new row

[](#insert-a-new-row)

```
$sheet->insert(array(
	"name" => "John",
	"age" => 23,
	"email" => "john@example.com"
));
```

### Update column's value

[](#update-columns-value)

```
$sheet->update(
	8, // row number
	"name", // field's name (or column number as Integer)
	"Tom"
);

$sheet->update(
	array(8,16,24), // row numbers
	"name",
	"Tom"
);

$sheet->update(
	array(
		"name" => "Tom" // condition to select
	),
	"email",
	"tom@example.com"
);

$sheet->update(
	function($row){
		return (int) $row["age"] > 80; // condition to select as closure
	},
	"active",
	"false"
);
```

### Get up-to-date table data

[](#get-up-to-date-table-data)

```
$items = $sheet->fetch(true)->items;
```

### Save cache

[](#save-cache)

```
$client->config(array(
	"cache" => true,
	"cache_dir" => "cache",
	"cache_expires" => 3600
));
```

Requirement
-----------

[](#requirement)

- [google/apiclient](https://github.com/google/google-api-php-client) (Apache License v2.0)

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 87.5% 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

Every ~78 days

Recently: every ~71 days

Total

8

Last Release

3352d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7ca20eda4a34e84bb976fab6d0ce5b7e0194364a434b2ec4f1cc7435ee0aec8a?d=identicon)[rationalboss](/maintainers/rationalboss)

---

Top Contributors

[![mach3](https://avatars.githubusercontent.com/u/342838?v=4)](https://github.com/mach3 "mach3 (14 commits)")[![rationalboss](https://avatars.githubusercontent.com/u/8023296?v=4)](https://github.com/rationalboss "rationalboss (2 commits)")

### Embed Badge

![Health badge](/badges/rationalboss-gsheet-manager/health.svg)

```
[![Health](https://phpackages.com/badges/rationalboss-gsheet-manager/health.svg)](https://phpackages.com/packages/rationalboss-gsheet-manager)
```

###  Alternatives

[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

81733.7k](/packages/flow-php-flow)[fleetbase/core-api

Core Framework and Resources for Fleetbase API

1225.0k10](/packages/fleetbase-core-api)[chameleon-system/chameleon-base

The Chameleon System core.

1026.5k3](/packages/chameleon-system-chameleon-base)[voidagency/vactory_starter_kit

Vactory is a custom Drupal profile which is developed and released by VOID Agency.

1019.7k](/packages/voidagency-vactory-starter-kit)

PHPackages © 2026

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