# Neo4j connect with PHP without framework

**URL:** <https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852>\
**Category:** Drivers & Stacks\
**Created:** [May 18, 2020, 10:59pm UTC](https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852 "2020-05-18T22:59:53Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![james3](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/james3/32/4104_2.png) [@james3](https://community.neo4j.com/u/james3)\
**Post date:** [May 18, 2020, 10:59pm UTC](https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852/1 "2020-05-18T22:59:53Z")

</div>

> **[GitHub - graphaware/neo4j-php-client: PHP Client for Neo4j with Enterprise...](https://github.com/graphaware/neo4j-php-client)**
>
> PHP Client for Neo4j with Enterprise Support. Contribute to graphaware/neo4j-php-client development by creating an account on GitHub.

I see the driver need Symfony Framework Bundle, but I develop PHP application without Framework.  
If I must install Symfony framework before using the driver of neo4j-php-client?

---

<div class="post-metadata">

**Author:** ![rteijeiro](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/rteijeiro/32/11569_2.png) [@rteijeiro](https://community.neo4j.com/u/rteijeiro)\
**Post date:** [May 19, 2020, 11:48am UTC](https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852/2 "2020-05-19T11:48:15Z")

</div>

Hi, I don't think you need the Symfony framework for a simple php application. The only think you have to do is to add the library to your project using composer and then create the connection as explained in the README like the following:

```auto
<?php

require_once 'vendor/autoload.php';

use GraphAware\Neo4j\Client\ClientBuilder;

$client = ClientBuilder::create()
    ->addConnection('default', 'http://neo4j:password@localhost:7474') // Example for HTTP connection configuration (port is optional)
    ->addConnection('bolt', 'bolt://neo4j:password@localhost:7687') // Example for BOLT connection configuration (port is optional)
    ->build();

```

Let me know if you have any other questions. We are currently working in the integration with Drupal in this module [https://www.drupal.org/project/neo4j](https://www.drupal.org/project/neo4j)

Good luck! 🙂

---

<div class="post-metadata">

**Author:** ![james3](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/james3/32/4104_2.png) [@james3](https://community.neo4j.com/u/james3)\
**Post date:** [May 21, 2020, 10:15pm UTC](https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852/3 "2020-05-21T22:15:47Z")

</div>

Thank you Ruben. I hope to learn how to CRUD neo4j with PHP no framework, can you provide a demo to me.Thank you very much.

---

<div class="post-metadata">

**Author:** ![rteijeiro](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/rteijeiro/32/11569_2.png) [@rteijeiro](https://community.neo4j.com/u/rteijeiro)\
**Post date:** [June 6, 2020, 11:02am UTC](https://community.neo4j.com/t/neo4j-connect-with-php-without-framework/18852/4 "2020-06-06T11:02:25Z")

</div>

This is an example of how to do it without any PHP framework but I don't think it's a good practice: [GitHub - graphaware/neo4j-php-ogm-tutorial: Code repository for the neo4j-php-ogm documentation's tutorial http://neo4j-php-ogm.readthedocs.io/en/latest/getting\_started/tutorial/](https://github.com/graphaware/neo4j-php-ogm-tutorial)

Have a look and let me know if you need any help.
